[ https://issues.apache.org/jira/browse/DRILL-3337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14596789#comment-14596789 ]
Abhishek Girish commented on DRILL-3337: ---------------------------------------- And CUME_DIST {code:sql} > SELECT c.c_first_name, c.c_last_name, CUME_DIST() OVER (PARTITION BY > s.ss_customer_sk ORDER BY s.ss_customer_sk) FROM customer c, store_sales s > WHERE c.c_customer_sk = s.ss_customer_sk GROUP BY c.c_first_name, > c.c_last_name, s.ss_quantity, s.ss_customer_sk ORDER BY 1, 2 LIMIT 20; Error: SYSTEM ERROR: org.apache.drill.exec.exception.SchemaChangeException: Failure while materializing expression. Error in expression at index 0. Error: Missing function implementation: [cume_dist(INT-REQUIRED)]. Full expression: null. Fragment 5:15 [Error Id: 2e970355-9d75-4aa0-aad9-92e9ed2171da on abhi8.qa.lab:31010] (state=,code=0) {code} > Queries with Window Function DENSE_RANK fail with SchemaChangeException > ----------------------------------------------------------------------- > > Key: DRILL-3337 > URL: https://issues.apache.org/jira/browse/DRILL-3337 > Project: Apache Drill > Issue Type: Bug > Components: Query Planning & Optimization > Affects Versions: 1.1.0 > Reporter: Abhishek Girish > Assignee: Aman Sinha > Labels: window_function > Attachments: drillbit.log.txt > > > Example queries which result in exceptions: > DENSE_RANK WF with ORDER BY 1 column and GROUP BY, ORDER BY on the main query > {code:sql} > SELECT DENSE_RANK() OVER (ORDER BY ss.ss_store_sk) FROM store_sales ss GROUP > BY ss.ss_store_sk, ss.ss_net_paid_inc_tax ORDER BY 1 LIMIT 20; > Error: SYSTEM ERROR: org.apache.drill.exec.exception.SchemaChangeException: > Failure while materializing expression. > Error in expression at index 0. Error: Missing function implementation: > [dense_rank(INT-REQUIRED)]. Full expression: null. > Fragment 4:10 > [Error Id: 4b9187db-e770-4e7f-afe4-0d4dfc045088 on abhi6.qa.lab:31010] > (state=,code=0) > {code} > DENSE_RANK WF with PARTITION BY 2 columns and ORDER BY 2 column and GROUP BY, > ORDER BY on the main query > {code:sql} > SELECT DENSE_RANK() OVER (PARTITION BY s.ss_store_sk, s.ss_customer_sk ORDER > BY s.ss_store_sk, s.ss_customer_sk) FROM store_sales s GROUP BY > s.ss_store_sk, s.ss_customer_sk, s.ss_quantity ORDER BY 1 LIMIT 20; > Error: SYSTEM ERROR: org.apache.drill.exec.exception.SchemaChangeException: > Failure while materializing expression. > Error in expression at index 0. Error: Missing function implementation: > [dense_rank(INT-REQUIRED)]. Full expression: null. > Fragment 5:22 > [Error Id: 3ac6e4ce-5bb3-4058-b806-3d0becbbd0d1 on abhi6.qa.lab:31010] > (state=,code=0) > {code} > *The queries execute fine on Postgres* -- This message was sent by Atlassian JIRA (v6.3.4#6332)