Update direct-db-connection.md
Updated the consolidateBy sentence.
This commit is contained in:
@@ -49,8 +49,6 @@ As you can see, the Grafana-Zabbix plugin uses aggregation by a given time inter
|
|||||||
## Functions usage with Direct DB Connection
|
## Functions usage with Direct DB Connection
|
||||||
|
|
||||||
|
|
||||||
There's only one function affecting the backend. This function is `consolidateBy`, which changes what data comes from
|
There's only one function that directly affects the backend data. This function is `consolidateBy`. Other functions work on the client side and transform data that comes from the backend. So you should clearly understand that this is pre-aggregated data (by AVG, MAX, MIN, etc).
|
||||||
the backend. Other functions still work on the client side and transform data that comes from the backend. So you should
|
|
||||||
clearly understand that this is pre-aggregated data (by AVG, MAX, MIN, etc).
|
|
||||||
|
|
||||||
For example, say you want to group values by 1 hour interval and `max` function. If you just apply `groupBy(10m, max)` function, your result will be wrong, because you would transform data aggregated by default `AVG` function. You should use `consolidateBy(max)` coupled with `groupBy(10m, max)` in order to get a precise result.
|
For example, say you want to group values by 1 hour interval and `max` function. If you just apply `groupBy(10m, max)` function, your result will be wrong, because you would transform data aggregated by default `AVG` function. You should use `consolidateBy(max)` coupled with `groupBy(10m, max)` in order to get a precise result.
|
||||||
|
|||||||
Reference in New Issue
Block a user