Luis Fernando Kauer created CALCITE-1999:
--------------------------------------------

             Summary: UNNEST generates a NPE when the parameter is null
                 Key: CALCITE-1999
                 URL: https://issues.apache.org/jira/browse/CALCITE-1999
             Project: Calcite
          Issue Type: Bug
            Reporter: Luis Fernando Kauer
            Assignee: Julian Hyde


It happens when trying to unnest a column with a nested collection when the 
column is null.
To reproduce it, I changed JdbcTest, addind a Department with a null collection 
of employees to HrSchema: 
{code:java}
     new Department(50, "NULL", null, null),
{code}
Just running the testCase JdbcTest.testUnnestArrayColumn() results in the NPE
NPE also happens running the following query:
{code:java}
select * from unnest(array(select * from \"hr\".\"depts\" where \"deptno\"=-1)) 
a
{code}




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to