[ https://issues.apache.org/jira/browse/CALCITE-1581?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16854376#comment-16854376 ]
Julian Hyde commented on CALCITE-1581: -------------------------------------- Also, there are some potential interactions with other SQL clauses. * Is it legal to use a TF in SELECT with GROUP BY? * Is it legal to use a TF in SELECT with HAVING? * Is it legal to use a TF in SELECT with ORDER BY? * Is it legal to use a TF in SELECT with a JOIN? * What if the JOIN has UNNEST? * Is it legal to use a TF in SELECT with other expressions in SELECT? * Is it legal to use a TF in SELECT inside an IN sub-query? * Is it legal to use a TF in SELECT with UNION? For each of these that are legal, I'd like to see a test that runs a query (thereby demonstrating that sql-to-rel conversion works); for of these that are illegal, let's document that it's not allowed, and have a validator test. Also test some combinations of the above (e.g. HAVING with and without GROUP BY); ORDER BY referencing columns by ordinal or alias. > UDTF like in hive > ----------------- > > Key: CALCITE-1581 > URL: https://issues.apache.org/jira/browse/CALCITE-1581 > Project: Calcite > Issue Type: New Feature > Reporter: Xiaoyong Deng > Assignee: pengzhiwei > Priority: Major > Labels: pull-request-available, udtf > Fix For: 1.20.0 > > Time Spent: 3h 10m > Remaining Estimate: 0h > > Support one row in and multi-column/multi-row out(one-to-many mapping), just > like udtf in hive. > The query would like this: > {code} > select > func(c0, c1) as (f0, f1, f2) > from table_name; > {code} > c0 and c1 are 'table_name' columns. f0, f1 and f2 are new generated columns. -- This message was sent by Atlassian JIRA (v7.6.3#76005)