You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by "duan xiong (Jira)" <ji...@apache.org> on 2021/10/11 01:29:00 UTC
[jira] [Created] (CALCITE-4846) When convert ROW values which
include NULL will generate the wrong type about whether nullable
duan xiong created CALCITE-4846:
-----------------------------------
Summary: When convert ROW values which include NULL will generate the wrong type about whether nullable
Key: CALCITE-4846
URL: https://issues.apache.org/jira/browse/CALCITE-4846
Project: Calcite
Issue Type: Bug
Affects Versions: 1.27.0
Reporter: duan xiong
Assignee: duan xiong
Run this SQL in JdbcExample :
{code:java}
select * from foodmart.sales_fact_1997 as s where s.cust_id not in (null, 100)
{code}
will throw an exception:
{noformat}
Caused by: org.apache.calcite.runtime.CalciteException: Cannot convert null to int{noformat}
Because when convert ROW values generate the wrong RelDataType:
{noformat}
type=RecordType(JavaType(int) ROW_VALUE),tuples=[{ null }, { 100 }]){noformat}
should be(nullable):
{noformat}
type=RecordType(INTEGER ROW_VALUE),tuples=[{ null }, { 100 }]){noformat}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)