-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GROUP BY time(x)
includes partial intervals
#8244
Comments
Whenever you have a query with a time range that includes a partial interval, it will still include the partial interval, but won't include data that doesn't fit inside of the time constraints. So in your example, if you query So I think this is expected behavior. Does that make sense? |
In my opinion including a partial interval feels wrong. It becomes quite troublesome when combining this with I would only expect a |
GROUP BY time(x)
extends queried timeGROUP BY time(x)
includes partial intervals
The big problem for this is when you're doing a |
So how to cut off the last incomplete interval? How you solved this @jomo ? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I guess this is still an issue? |
Yes, it is... |
oh please +1, just started using influx this week, and this has been driving me crazy... |
Having exactly the same behaviour... any update on this? |
I had this problem, and was about to report when I found this gh issue. I'm not sure if it's a feature or a bug? Was a two week long headache to track down exactly why my data was being corrupted. |
This is an issue for pretty much every aggregated graph I create in Grafana. If you do sum or mean or some other aggregator and group by a time range then the last time range will always show an oddly low, high or incorrect value. I imagine every single user of influx/grafana encounters this exact issue. It would be great to have an "exclude incomplete group" or "exclude most recent group" option. The other possibility would be to have an option of group by NOT aligned to, say, hour. So if I group by hour and the current time is 3:15, then the group will be 2:15-3:15 instead of 2:00-3:00 and 3:00-4:00 |
+1 If anyone is still paying attention. I'm monitoring a lot of volumes using COUNT() and the latest value is always too low which is an issue for alerting. |
+1 |
+1, driving me absolutely nuts. I need to count over 10s and select the last value to display in a card to use it as a warning indicator if things are wrong. I am now consistently getting the wrong value. |
Statistics for CRUD module was introduced in CRUD 0.11.0 [1]. To enable statistics integrated with metrics with quantiles, call crud.cfg{ stats = true, stats_driver = 'metrics', stats_quantiles = true } This patch adds panels for - tnt_crud_stats summary (+ tnt_crud_stats_count, tnt_crud_stats_sum) - tnt_crud_tuples_fetched - tnt_crud_tuples_lookup - tnt_crud_map_reduces There is a group of panels for RPS load and a group of panels with latency, both consists of separate panels for each operation and ok/error status. Tuples panels are displayed as average per request. InfluxDB queries for tuple panels have minor issue: they can show 0 current value from time to time due to `fill(0)` and `GROUP BY` including partial intervals [2]. Map reduces panel show average RPS. 1. https://github.com/tarantool/crud/releases/tag/0.11.0 2. influxdata/influxdb#8244 Closes #143
Statistics for CRUD module was introduced in CRUD 0.11.0 [1]. To enable statistics integrated with metrics with quantiles, call crud.cfg{ stats = true, stats_driver = 'metrics', stats_quantiles = true } This patch adds panels for - tnt_crud_stats summary (+ tnt_crud_stats_count, tnt_crud_stats_sum) - tnt_crud_tuples_fetched - tnt_crud_tuples_lookup - tnt_crud_map_reduces CRUD panels are stored in "CRUD module statistics" section. There is a group of panels for RPS load and a group of panels with latency, both consists of separate panels for each operation and ok/error status. Tuples panels are displayed as average per request. InfluxDB queries for tuple panels have minor issue: they can show 0 current value from time to time due to `fill(0)` and `GROUP BY` including partial intervals [2]. Map reduces panel show average RPS. 1. https://github.com/tarantool/crud/releases/tag/0.11.0 2. influxdata/influxdb#8244 Closes #143
Statistics for CRUD module was introduced in CRUD 0.11.0 [1]. To enable statistics integrated with metrics with quantiles, call crud.cfg{ stats = true, stats_driver = 'metrics', stats_quantiles = true } This patch adds panels for - tnt_crud_stats summary (+ tnt_crud_stats_count, tnt_crud_stats_sum) - tnt_crud_tuples_fetched - tnt_crud_tuples_lookup - tnt_crud_map_reduces CRUD panels are stored in "CRUD module statistics" section. There is a group of panels for RPS load and a group of panels with latency, both consists of separate panels for each operation and ok/error status. Tuples panels are displayed as average per request. InfluxDB queries for tuple panels have minor issue: they can show 0 current value from time to time due to `fill(0)` and `GROUP BY` including partial intervals [2]. Map reduces panel show average RPS. 1. https://github.com/tarantool/crud/releases/tag/0.11.0 2. influxdata/influxdb#8244 Closes #143
Statistics for CRUD module was introduced in CRUD 0.11.0 [1]. To enable statistics integrated with metrics with quantiles, call crud.cfg{ stats = true, stats_driver = 'metrics', stats_quantiles = true } This patch adds panels for - tnt_crud_stats summary (+ tnt_crud_stats_count, tnt_crud_stats_sum) - tnt_crud_tuples_fetched - tnt_crud_tuples_lookup - tnt_crud_map_reduces CRUD panels are stored in "CRUD module statistics" section. There is a group of panels for RPS load and a group of panels with latency, both consists of separate panels for each operation and ok/error status. Tuples panels are displayed as average per request. InfluxDB queries for tuple panels have minor issue: they can show 0 current value from time to time due to `fill(0)` and `GROUP BY` including partial intervals [2]. Map reduces panel show average RPS. 1. https://github.com/tarantool/crud/releases/tag/0.11.0 2. influxdata/influxdb#8244 Closes #143
Bug report
System info: InfluxDB version 1.2.1
Steps to reproduce:
Example: Insert data at
00:00:30
,00:01:30
,00:02:30
, …SELECT mean(value) FROM data WHERE time <= now() GROUP BY time(1m)
Expected behavior:
I would expect InfluxDB to only group time ranges that fully fit the into the queried time range (in this case, time ranges that have already passed)
Example:
now()
) is00:01:01
00:00:00 - 00:01:00
time
field of the result should be00:00:00
or00:01:00
)Actual behavior:
InfluxDB groups time ranges extending the queried time, in this example meaning as soon as
00:01:00
passes, it will group00:01:00 - 00:02:00
. With data only being inserted at00:01:30
, the last result will benull
(until00:01:30
passes), although data is inserted with the same interval as used in the query.Additional info:
Related issues: #3926 #4282 #4038 #8010
The text was updated successfully, but these errors were encountered: