提交 7e8bf7f6 编写于 作者: O obdev 提交者: 羽飞

[CP] fix json output type

上级 39fd66a5
......@@ -135,11 +135,12 @@ public:
set_collation_type(CS_TYPE_INVALID);
} else if (ObHexStringType == type_) {
set_collation_type(CS_TYPE_BINARY);
} else if (ob_is_json(static_cast<ObObjType>(type_))) {
set_collation_type(CS_TYPE_UTF8MB4_BIN);
} else if (!ob_is_string_type(static_cast<ObObjType>(type_)) &&
!ob_is_lob_locator(static_cast<ObObjType>(type_)) &&
!ob_is_raw(static_cast<ObObjType>(type_)) &&
!ob_is_enum_or_set_type(static_cast<ObObjType>(type_)) &&
!ob_is_json(static_cast<ObObjType>(type_))) {
!ob_is_enum_or_set_type(static_cast<ObObjType>(type_))) {
set_collation_level(CS_LEVEL_NUMERIC);
set_collation_type(CS_TYPE_BINARY);
}
......
......@@ -3285,7 +3285,6 @@ int ObAggregateFunction::get_json_arrayagg_result(const ObAggregateExpression *&
LOG_WARN("convert string collation failed", K(ret), K(cs_type), K(origin_str.length()));
} else {
converted_obj.set_string(val_type, converted_str);
converted_obj.set_collation_type(CS_TYPE_UTF8MB4_BIN);
cs_type = CS_TYPE_UTF8MB4_BIN;
}
}
......@@ -3430,7 +3429,6 @@ int ObAggregateFunction::get_json_objectagg_result(const ObAggregateExpression *
LOG_WARN("convert string collation failed", K(ret), K(cs_type1), K(origin_str.length()));
} else {
converted_obj.set_string(val_type1, converted_str);
converted_obj.set_collation_type(CS_TYPE_UTF8MB4_BIN);
cs_type1 = CS_TYPE_UTF8MB4_BIN;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册