Open mjf opened 3 years ago
Hi @mjf
The team that deals with Grafana has been intimated about this. They will take a look soon.
@nikkhils That's great! Thank you.
Hi @nikkhils do you have any news about this, please?
@cevian can you help out here?
I'll have to look at the semantics Grafana expects (inclusive or exclusive). Not sure which is right here. @svenklemm originally wrote the DS so he may be able to help here as well.
I think you want lower inclusive and upper exclusive. Upper inclusive and lower exclusive would work too but might be a little weird since time_bucket returns lower. Currently it does both inclusive which leads to double counting if values are exactly on the boundary. If you were to switch to both exclusive that would lead to missing counts for values that are exactly on boundary.
@nikkhils, @svenklemm, @cevian Hi guys, any update on this, please?
The Postgres data source (DS) in Grafana uses the SQL
BETWEEN
operator for the"time"
column which can be incorrect for edge-cases (see "Don't Do This"). Provide new switch in the Postgres DS settings to replace theBETWEEN
operator in the DS macros (preferably defaulting to be switched on for TimescaleDB-enabled DS and switched off for the Postgres-only DS).