You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/06/26 23:52:49 UTC

[GitHub] [arrow-datafusion] kmitchener opened a new issue, #2798: panic when case statement returns null

kmitchener opened a new issue, #2798:
URL: https://github.com/apache/arrow-datafusion/issues/2798

   **Describe the bug**
   A clear and concise description of what the bug is.
   
   I've boiled this down to a small test case which panics with this error:
   thread 'main' panicked at 'NullArray data should not contain a null buffer, as no buffers are required'
   
   **To Reproduce**
   Steps to reproduce the behavior:
   
   run this SQL from cli:
   select case when b is null then null else b end from (select a,b from (values (1,null),(2,3)) as t (a,b)) a;
   
   **Expected behavior**
   A clear and concise description of what you expected to happen.
   
   In Postgres, it returns "null" and 3, as expected.
   
   **Additional context**
   Add any other context about the problem here.
   
   Also, this query returns wrong results, as compared to PG:
   select case when b is null then null else b end from (select a,b from (values (1,1),(2,3)) as t (a,b)) a;
   
   in PG, that returns 2 rows: 1 and 3. In Datafusion, it returns 2 nulls.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow-datafusion] rostamn739 commented on issue #2798: panic when case statement returns null

Posted by GitBox <gi...@apache.org>.
rostamn739 commented on issue #2798:
URL: https://github.com/apache/arrow-datafusion/issues/2798#issuecomment-1166717931

   also happens with
   `select case when b is null then null else b end from (select a,b from (values (1,1),(2,null)) as t (a,b)) a;`
   
   
   but does not happen with
   `select case when b is null then null else 1 end from (select a,b from (values (1,null),(2,3)) as t (a,b)) a;`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [arrow-datafusion] alamb closed issue #2798: panic when case statement returns null

Posted by GitBox <gi...@apache.org>.
alamb closed issue #2798: panic when case statement returns null
URL: https://github.com/apache/arrow-datafusion/issues/2798


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org