ajcrutch commented on issue #7953: Exact distinct-COUNT with complex expression 
(CASE, IN) throws NullPointerException
URL: 
https://github.com/apache/incubator-druid/issues/7953#issuecomment-510700582
 
 
   This also produces an error with the count(*) but not without it.
   
   SELECT 
   COUNT(*) AS "sales_order_detail.count",
   COUNT(DISTINCT sales_order_detail.order_nbr) FILTER(WHERE 
sales_order_detail.source_system_id = '7')
   AS "sales_order_detail.return_orders"
   FROM  druid.sales_order_detail  AS sales_order_detail
   LIMIT 500
   
   The Druid database encountered an error while running this query.
   Error -1 (00000) : Error while executing SQL: Remote driver error: 
RuntimeException: Error while applying rule 
AggregateExpandDistinctAggregatesRule, args 
[rel#25830:LogicalAggregate.NONE.[](input=rel#25829:Subset#2.NONE.[],group={},sales_order_detail.count=COUNT(),sales_order_detail.return_orders=COUNT(DISTINCT
 $0) FILTER $1)] -> NullPointerException: (null exception message)
   

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


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to