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

Sean Broeder commented on CALCITE-7831:
---------------------------------------

Found while testing CALCITE-7791

> CompileException casting a ROW array literal to Object[]
> --------------------------------------------------------
>
>                 Key: CALCITE-7831
>                 URL: https://issues.apache.org/jira/browse/CALCITE-7831
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>            Reporter: Sean Broeder
>            Priority: Major
>
> CAST(ARRAY[ROW(1)] AS ROW(a INTEGER) ARRAY) fails at runtime on main  
>     select * from unnest(cast(array[row(1)] as row(a integer) array))
>   throws:
>     org.apache.calcite.runtime.CalciteContextException: ...
>     Caused by: org.codehaus.commons.compiler.CompileException:
>     Cannot cast "Baz$Record1_0" to "java.lang.Object[]"
>     
> The validator and SqlToRelConverter both handle this literal correctly
> in CALCITE-7791, but code generation for the runtime CAST from the
> literal's generated record class to Object[] is broken, so no end to end
> test can use this literal.



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

Reply via email to