You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2018/07/31 07:34:52 UTC

[GitHub] kskalski commented on issue #5566: Applying doubleSum over doubleFirst aggregations in nested groupBy fails

kskalski commented on issue #5566: Applying doubleSum over doubleFirst aggregations in nested groupBy fails
URL: https://github.com/apache/incubator-druid/issues/5566#issuecomment-409125068
 
 
   @jihoonson thanks for the tip, indeed this makes the query work fine. I'm wondering though, if this use-case shouldn't be possible to handle automatically. In fact Druid has the concept of "finalized" and not-finalized values from aggregators and it can apply it correctly to first/last aggregators, which implement that pattern, e.g.:
   
   ```
   {
       "queryType": "groupBy",
       "dataSource": "pm_data",
       "aggregations":[{ "type": "doubleFirst", "name": "value_num", "fieldName": "value_num" }],
       "dimensions": ["counter_id"],
       "intervals": "2017-06-30T00:00:00/2017-07-02T16:46:40",
       "filters": {"type": "selector", "dimension": "version", "value": "43:48501"},
       "granularity": "day"
   }
   ```
   
   works fine returning just value num without using expression postaggregator. Shouldn't it also apply the same logic in nested query? I suppose outer query will always treat its input as finalized, so in essence the nested query should finalize its results.
   
   Actually, I would like to know how the mechanizm of finalizing results works, since I also had similar problem using Java client classes (_com.simplaex.clients.druid.DruidClient_, which I know is not supported approach, but still might shed some light on the issue here) when executing above (non-nested) group_by query - the client was not able to parse the results correctly, so I suppose there is some trick / special postprocessing / flag forcing finalization of results.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org