[fix](Nereids) cast from json should always nullable (#34707)

This commit is contained in:
morrySnow
2024-05-13 14:42:04 +08:00
committed by yiguolei
parent 5012ddd87a
commit c71d0b6b22
2 changed files with 20 additions and 0 deletions

View File

@ -79,6 +79,8 @@ public class Cast extends Expression implements UnaryExpression {
return true;
} else if (!childDataType.isTimeLikeType() && targetType.isTimeLikeType()) {
return true;
} else if (childDataType.isJsonType()) {
return true;
} else {
return child().nullable();
}