Separate time scales not displaying correctly

I have an InfluxDB time series with a long time scale for the main graphs, and they seem to work perfectly fine. However, some of the graphs I only want to show for one day (1d). The graphs that are only supposed to show one day are only showing the previous six hours instead. It doesn’t matter if I set it to “1d” or “24h;” the result is the same.

These are the settings for the Lower Left graph:

Relative time: Overrides the relative time range for individual panels, which causes them to be different than what is selected in the dashboard time picker in the top-right corner of the dashboard. You can use this to show metrics from different time periods or days on the same dashboard.

Note: Panel time overrides have no effect when the dashboard’s time range is absolute.

Your dashboard has selected absolute time range, so that config is ignored.

So how then do I get it to show “all” the data I want? I must be missing a concept. The data I have goes before the time I’ve put in above. But the visualizations only grab from the time up the top. The three graphs have 1d as their Relative Time.

What should I be setting?


This, if I hover over above it suggests it’s picking the right values, but it’s not displaying the correct values in the graph.

You need to change your range statement to start at the time & date when your data starts, e.g.
|> range(start: 2021-05-22T23:30:00Z)
This will ignore the Time Picker range, but depending on how you are aggregating or downsampling your data, you might have to click thru this:
image

Haha… yeah. I’m lost… which one am I changing? I want it to show starting from “24 hours from now” until “now” for those three graphs at the bottom… All the other graphs I want to show from the value up the top of the screen.

For those 3 graphs, change the range statement to

from(bucket: "hacore")
    |> range(start: -24h)

More info and examples:

That gives me this once I remove the settings in the query options. Leaving them there generates no difference to the graphs above:

What about this?

Same Result:

I believe this is happening because you have selected an absolute time range in the time picker, and as @jangaraj stated, when you do this, that config is ignored. From the docs he linked to: Panel time overrides have no effect when the dashboard’s time range is absolute.

I think I understand what you mean… however I changed it to one of the drop-down options that is similar to that time frame, but it show the same result as if I used an absolute date"

Any more ideas of what I could try?

@nat5 Can you share the queries and query option settings for the 3 green graphs?

They are all identical, besides the value in the InfluxDB


OK, so I am speculating that perhaps these lines are truncating the results to display only the past 6 hours. If you remove one or both, does the graph change to show 24 hours?

It doesn’t seem to have made a difference:

You can see that it’s actually “getting” the correct data but it’s simply not displaying it in the graph:

And toggling to Table view (as well as changing the Time Picker to Last 90 days) also shows the last 24 hours of data in a table format?
image

It shows the previous 24 hours like I would expect it should:

So I’ve done the same checks and proposed changes on my test system and it always works as it should, so I’m just about out of suggestions.

If you start with a new dashboard and create new graphs with Query options >> Relative time: now - 24h does it also exhibit this behavior where it only shows you the past 6 hours?

OK… so I recreated the dashboard from scratch and copied the same code and the same absolute time and this time it seemed to work without any issues:

1 Like