cloud-fan commented on a change in pull request #29626:
URL: https://github.com/apache/spark/pull/29626#discussion_r481897176



##########
File path: sql/core/src/test/resources/sql-tests/results/group-by-filter.sql.out
##########
@@ -150,6 +150,38 @@ struct<count(DISTINCT id) FILTER (WHERE false):bigint>
 0
 
 
+-- !query
+SELECT COUNT(DISTINCT id), COUNT(DISTINCT 2,3) FILTER (WHERE dept_id = 40) 
FROM emp
+-- !query schema
+struct<count(DISTINCT id):bigint,count(DISTINCT 2, 3) FILTER (WHERE (dept_id = 
40)):bigint>
+-- !query output
+8      0
+
+
+-- !query
+SELECT COUNT(DISTINCT id), COUNT(DISTINCT 3,2) FILTER (WHERE dept_id = 40) 
FROM emp
+-- !query schema
+struct<count(DISTINCT id):bigint,count(DISTINCT 3, 2) FILTER (WHERE (dept_id = 
40)):bigint>
+-- !query output
+8      0
+
+
+-- !query
+SELECT COUNT(DISTINCT id), COUNT(DISTINCT 2,3) FILTER (WHERE dept_id = 30) 
FROM emp

Review comment:
       can we test `WHERE dept_id > 0`? to make sure that we get correct result 
even if there are more than one inputs after filter.




----------------------------------------------------------------
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]



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

Reply via email to