You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
A clear and concise description of what the bug is.
The type of case expression is not checked when building the plan.
To Reproduce
DataFusion CLI v15.0.0
❯ create table t asselect2as a;
0 rows inset. Query took 0.013 seconds.
❯ select case
when a =1 then true
when a =2 then 'abc'
else 123
end
from t;
Internal("The type of Boolean AND Utf8 of binary physical should be same")
Expected behavior
We should return a DatafusionError::Plan(...), instead of an Internal error.
Describe the bug
A clear and concise description of what the bug is.
The type of
case
expression is not checked when building the plan.To Reproduce
Expected behavior
We should return a
DatafusionError::Plan(...)
, instead of anInternal
error.Additional context
The
CaseBuilder
does some type checking, but it seems that it is bypassed.https://github.com/apache/arrow-datafusion/blob/c2f199adbec8b650de5668c97675f8a757607df8/datafusion/expr/src/conditional_expressions.rs#L100-L110
when
exprthen
andelse
The text was updated successfully, but these errors were encountered: