[ 
https://issues.apache.org/jira/browse/CALCITE-7027?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17952942#comment-17952942
 ] 

Mihai Budiu commented on CALCITE-7027:
--------------------------------------

I think he has added some positive tests too, so he does want to support them.

> SqlUtil#getSelectListItem doesn't support union, intersect, except
> ------------------------------------------------------------------
>
>                 Key: CALCITE-7027
>                 URL: https://issues.apache.org/jira/browse/CALCITE-7027
>             Project: Calcite
>          Issue Type: Improvement
>          Components: core
>            Reporter: Sergey Nuyanzin
>            Assignee: Sergey Nuyanzin
>            Priority: Major
>              Labels: pull-request-available
>
> -We have our exception classification system internally which based on cause 
> decides whether it is a user exception or not. Since currently there 
> {{Util#needToImplement}} which might be thrown from multiple places. We 
> prefer to not include the whole variety of {{Util#needToImplement}} to user 
> error since it would be tricky to control.-
> -The proposal is to introduce also some message part which could allow to add 
> more context what exactly is not implemented-
> -Also open to other suggestions-
> UPD: it looks the reason of failures we faced is unsupported {{UNION}}, 
> {{INTERSECT}}, {{EXCEPT}}, {{MINUS}} in {{SqlUtil#getSelectListItem}}
> renamed jira issue 
> to reproduce
> {code:sql}
> SELECT name FROM dept UNION SELECT name FROM dept UNION SELECT slacker FROM 
> emp
> {code}
> currently fails with
> {noformat}
> Caused by: java.lang.UnsupportedOperationException: class 
> org.apache.calcite.sql.SqlBasicCall: SELECT `NAME`
> FROM `DEPT`
> UNION
> SELECT `NAME`
> FROM `DEPT`
> {noformat}
> while the issue is type mismatch column
> after the fix it should fail as
> {noformat}
> Type mismatch in column 1 of UNION
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to