COUNT([DISTINCT] expression)



The following program shows the query for this function −

Query

0: jdbc:drill:zk = local> select count(distinct(mark3)) from dfs.`/Users/../workspace/Drill-samples/student_list.json`;

Result

EXPR$0
9

count(distinct(mark3)) returns the no of distinct records for the column mark3.

apache_drill_query_using_json.htm
Advertisements