Ken Krugler07/16/2021, 9:59 PM
. I get a single row as expected, but with a
select sum(metric), key, min(date) as firstSeen, max(date) as lastSeen from table where date >= <lowDate> AND date <= <highDate> group by key order by firstSeen desc limit 1
both equal to
. I was expecting the
result to be equal to
. If I then run the exact same query, but add in
, I get the a single row with the requested key value, but now the
AND key = '<key value from the previous result>'
result is equal to
(as expected), and
is larger (also as expected). Any ideas what is going on?
Jackie07/16/2021, 10:06 PM
select date from table where date >= <lowDate> AND date <= <highDate> AND key = '<key value from the previous result>'
a very high cardinality column? If so, some groups might be dropped due to Pinot's approximation algorithm for group-by queries
Ken Krugler07/16/2021, 10:09 PM
in response. And the difference is for a specific key value, not a missing key value.
, I get four rows. The sum of the metric values is the larger (expected) value. The one row with
select date,metric from table WHERE date >= <lowDate> AND date <= <highDate> AND key = '<key value from previous result>'
date = <highDate>
value = the
returned from the first query.
(instead of by
order by lastSeen
), the results are more correct.
seems right for the various rows I get back, and the
almost matches what I get when I add the
AND key = 'specific key value'