How to graph this day and yesterday on the same graph

I’m creating a graph or dashboard that compares yesterday’s and today’s usage.
I want to display this on one table panel.
I’m using grafna 7.0 and I’m using influxdb with it.

What should I do to get the data from a day earlier rather than the $timeFilter variable?

SELECT mean(“active”) FROM “mem” WHERE (What should I input into this?) (“host” = ‘pepsi_zero_suge’) AND GROUP BY time($__interval) fill(null)

Hi @sikim920115! I am not familiar with influxDB queries but maybe, something like this could help you?
select dateadd(day, 1, date_column) as time,
“active” as metric,
avg(*) as value
from mem
where host = ‘pepsi_zero_usage’
and status_column = ‘active’
and date_column between dateadd(day, -1, $__from:date) and dateadd(day, -1, $__to:date);

Now, I know this might not exactly work for you but what I am implying is you could use the $__from:date and $__to:date global variables and manipulate them to get yesterday’s data and then map it to the same time for today, just so Grafana can understand they need to be plotted on the same x-axis point in your graph.
Hope this helps!