I read/tried plenty of aggregation examples but I still cannot come up with the complete solution
I need to display new users over the week (day/month) trend chart. In SQL it may look like this:
select count(email) from hits group by email having sum(case when logged_at < '2020-02-01' then 1 else 0 end) = 0 -- '2020-02-01' reflects last week and will be eventually a param
How to do the same by aggregation and display in Grafana?