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

xiong duan commented on CALCITE-6437:
-------------------------------------

Hi [~albericbyte] , I check this in the Calcite. It  can all works well:
{code:java}
select JSON_OBJECT('name': dname, 'type': deptno) from dept;
select JSON_OBJECT('name': 'foo', 'type': 'VARCHAR');{code}
Can you try to reproduce this bug in the Calcite and Please add unit test for 
this. We can make this issue more clearly.

> For druid sql JSON_OBJECT() function results in RUNTIME_FAILURE when querying 
> INFORMATION_SCHEMA.COLUMNS
> --------------------------------------------------------------------------------------------------------
>
>                 Key: CALCITE-6437
>                 URL: https://issues.apache.org/jira/browse/CALCITE-6437
>             Project: Calcite
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.35.0
>            Reporter: AlbericByte
>            Priority: Critical
>              Labels: pull-request-available
>
> there is but for druid sql :
> [https://github.com/apache/druid/issues/16356]
> h3. Description
> Running the following query
> {code:java}
> select JSON_OBJECT('name': COLUMN_NAME, 'type': DATA_TYPE) from 
> INFORMATION_SCHEMA.COLUMNS{code}
> {{ }}
>  
> produces
> {code:java}
> Error: RUNTIME_FAILURE (OPERATOR) cannot translate call json_object($t17, 
> $t18, $t3, $t19, $t7) java.lang.RuntimeException   {code}
>  
> Note that the error message quotes the json_object call to receive five 
> parameters, but maybe that's an unrelated internal detail.
> For comparison, the following works (but is useless):
> {code:java}
> select JSON_OBJECT('name': 'foo', 'type': 'VARCHAR'){code}



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

Reply via email to