[CP][BUGFIX] fix repeat deduce text type compat

This commit is contained in:
skylhd
2023-09-20 15:17:00 +00:00
committed by ob-robot
parent cfdf9c8089
commit c2dfd2792f

View File

@ -47,9 +47,7 @@ int ObExprRepeat::calc_result_type2(ObExprResType &type,
{ {
int ret = OB_SUCCESS; int ret = OB_SUCCESS;
if (GET_MIN_CLUSTER_VERSION() < CLUSTER_VERSION_4_2_0_0) { if (GET_MIN_CLUSTER_VERSION() < CLUSTER_VERSION_4_2_0_0) {
if (!text.is_string_type()) { text.set_calc_type(common::ObVarcharType);
text.set_calc_type(common::ObVarcharType);
}
} else if (!ob_is_text_tc(text.get_type()) && !text.is_null()) { } else if (!ob_is_text_tc(text.get_type()) && !text.is_null()) {
text.set_calc_type(common::ObVarcharType); text.set_calc_type(common::ObVarcharType);
} }