Adrian - Hi, I am trying to filter liveboard da...

Hi, I am trying to filter liveboard data by "On or before Today" by triggering a HostEvent.UpdateFilters . Can anyone tell me how the "filter object" should look like?
14 Replies
shikharTS
shikharTS2mo ago
Embed a Liveboard
You can use the LiveboardEmbed SDK library to embed a ThoughtSpot Liveboard in your app and use it for live insights
Adrian
AdrianOP2mo ago
No, can you share what exactly should "filter object" include? What oper, type and what values
shikharTS
shikharTS2mo ago
HostEvent
Event types that can be triggered by the host application to the embedded ThoughtSpot app.
Adrian
AdrianOP2mo ago
Can you actually answer my question. I've seen all the docs end there is no example of filtering by "Data column" by "On or before Today". I tried what you have in docs but nothing is working. With that said, can you share with me the exact schape of the filter object, please? I need exact values for oper , type and values to filter by "On or before Today".
shikharTS
shikharTS2mo ago
filter: { column: "date", oper: "LE", values: ["This day"], type: "THIS_PERIOD" } This should work. We have given type THIS_PERIOD in the docs. Did you try this? Did this not work?
Adrian
AdrianOP2mo ago
I tried this and I get an error: "Invalid date filter proto type: THIS_PERIOD op: LE"
shikharTS
shikharTS2mo ago
Let me try it locally on a cluster and give you the value
Adrian
AdrianOP2mo ago
Just so you know, when I want to use date range, it works.
{
column: 'Date',
oper: RuntimeFilterOp.BW_INC,
values: ['2024-01-01', '2025-01-01'],
type: 'EXACT_DATE_RANGE',
}
{
column: 'Date',
oper: RuntimeFilterOp.BW_INC,
values: ['2024-01-01', '2025-01-01'],
type: 'EXACT_DATE_RANGE',
}
shikharTS
shikharTS2mo ago
Seems like there is a miss in the docs. There is a keyword that seems to be missing when using THIS_PERIOD. Can you try this and see if this works:
filter: {
column: "date",
oper: "LE",
datePeriod: "DAY",
//values: ["This day"],
type: "THIS_PERIOD"
}
filter: {
column: "date",
oper: "LE",
datePeriod: "DAY",
//values: ["This day"],
type: "THIS_PERIOD"
}
Note: values is not required here
Adrian
AdrianOP2mo ago
This works but it is a different filter (shows as "On or before This Day" instead of "On or before Today 14/03/2025"). I believe it means pretty much the same but I'd like to know how to filter by "On or before Today". It is there so there should be a way.
Adrian
AdrianOP2mo ago
No description
Adrian
AdrianOP2mo ago
No description
shikharTS
shikharTS2mo ago
I am unable to create this filter. Seems there might be a bug here. For now can you use the on or before this day, will file a bug with the internal team to correct this
Adrian
AdrianOP2mo ago
Ok, I'll use the on or before this day. Please, let me know when you have any info from you internal team.

Did you find this page helpful?