summaryrefslogtreecommitdiffstats
path: root/web/api/queries/query.c
diff options
context:
space:
mode:
Diffstat (limited to 'web/api/queries/query.c')
-rw-r--r--web/api/queries/query.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/web/api/queries/query.c b/web/api/queries/query.c
index 95ddc125e7..d03b43d3c7 100644
--- a/web/api/queries/query.c
+++ b/web/api/queries/query.c
@@ -871,8 +871,11 @@ RRDR *rrd2rrdr(
for(rd = st->dimensions, c = 0 ; rd && c < dimensions_count ; rd = rd->next, c++) {
// if we need a percentage, we need to calculate all dimensions
- if(unlikely(!(options & RRDR_OPTION_PERCENTAGE) && (r->od[c] & RRDR_DIMENSION_HIDDEN)))
+ if(unlikely(!(options & RRDR_OPTION_PERCENTAGE) && (r->od[c] & RRDR_DIMENSION_HIDDEN))) {
+ if(unlikely(r->od[c] & RRDR_DIMENSION_SELECTED)) r->od[c] &= ~RRDR_DIMENSION_SELECTED;
continue;
+ }
+ r->od[c] |= RRDR_DIMENSION_SELECTED;
// reset the grouping for the new dimension
r->internal.grouping_reset(r);