I have a dashboard with an organization filter on it and I am wondering based on the organization that users select, whether I can write something like this in my sql-derived table. Basically, each organization has a different max date and I want to only output the data that is from that max_date like so:
Steps:
** Dashboard user selects Organization A on the dashboard **
My sql-derived table:
WHERE date(run_time) = (select max(date) from table where organization_name = {{ _filters['viewname.value'] }})
..where {{ _filters['viewname.value'] }}) equals Organization A, the org that the user selected in the dashboard filter.
^ the above is obviously not working but I hope it shows what I’m trying to do.
Best answer by Jimmy_Westman
View original