[enhance](nereids) tightestCommonType of datetime and datev2 is datev2 (#16086)
in original planner, tightestCommonType of datetime and datev2 is datev2. make nereids compatible with original planner.
This commit is contained in:
@ -234,10 +234,10 @@ public class TypeCoercionUtils {
|
||||
tightestCommonType = left;
|
||||
} else if (right instanceof DateTimeV2Type) {
|
||||
tightestCommonType = right;
|
||||
} else if (left instanceof DateTimeType || right instanceof DateTimeType) {
|
||||
tightestCommonType = DateTimeType.INSTANCE;
|
||||
} else if (left instanceof DateV2Type || right instanceof DateV2Type) {
|
||||
tightestCommonType = DateV2Type.INSTANCE;
|
||||
} else if (left instanceof DateTimeType || right instanceof DateTimeType) {
|
||||
tightestCommonType = DateTimeType.INSTANCE;
|
||||
}
|
||||
} else if (left instanceof DoubleType && right instanceof DecimalV2Type
|
||||
|| left instanceof DecimalV2Type && right instanceof DoubleType) {
|
||||
|
||||
Reference in New Issue
Block a user