I have added a dashboard with date filter, which is working fine for Bar or line charts because they have date filed to attach.
But in case of pie chart I don't have date fields which I can attach to it. Any suggestion how to do this.
My Pie chart based question is something like this. Without dashboard chart is working fine with filters.
select t.a, SUM(t.tt) from (select action as a, action_type as at,
NULLIF(metadata->'total_time', '')::int as tt,
CAST(created_at AS date) as d
from action_histories) as t
where
t.tt >= '0' and t.at = 0 [[and (t.d BETWEEN {{StartDate}} AND {{EndDate}})]]
group by t.a;