Fix ctas unknown cast type

This commit is contained in:
obdev
2023-02-08 15:27:28 +08:00
committed by ob-robot
parent 244baaa7f1
commit b385e569a2
2 changed files with 13 additions and 0 deletions

View File

@ -430,6 +430,10 @@ int ObExprCast::calc_result_type2(ObExprResType &type,
ObAccuracy acc = ObAccuracy::DDL_DEFAULT_ACCURACY2[compatibility_mode][dst_type.get_type()];
type.set_accuracy(acc);
type1.set_accuracy(acc);
} else if (ObYearType == dst_type.get_type()) {
ObAccuracy acc = ObAccuracy::DDL_DEFAULT_ACCURACY2[compatibility_mode][dst_type.get_type()];
type.set_accuracy(acc);
type1.set_accuracy(acc);
} else {
type.set_precision(dst_type.get_precision());
}