fix param info field is not deep copied

This commit is contained in:
obdev
2023-03-13 08:41:04 +00:00
committed by ob-robot
parent 4ae800e828
commit 830b1e3d76

View File

@ -346,10 +346,17 @@ int ObGVSql::fill_cells(const ObILibCacheObject *cache_obj, const ObPlanCache &p
} }
case share::ALL_VIRTUAL_PLAN_STAT_CDE::PARAM_INFOS: { case share::ALL_VIRTUAL_PLAN_STAT_CDE::PARAM_INFOS: {
if (cache_obj->is_sql_crsr()) { if (cache_obj->is_sql_crsr()) {
cells[i].set_lob_value(ObLongTextType, plan->stat_.param_infos_.ptr(), ObString param_info_lob_str;
static_cast<int32_t>(plan->stat_.param_infos_.length())); if (OB_FAIL(ob_write_string(*allocator_,
cells[i].set_collation_type(ObCharset::get_default_collation( plan->stat_.param_infos_,
ObCharset::get_default_charset())); param_info_lob_str))) {
SERVER_LOG(ERROR, "copy param_infos failed", K(ret));
} else {
cells[i].set_lob_value(ObLongTextType, param_info_lob_str.ptr(),
static_cast<int32_t>(param_info_lob_str.length()));
cells[i].set_collation_type(ObCharset::get_default_collation(
ObCharset::get_default_charset()));
}
} else { } else {
cells[i].set_null(); cells[i].set_null();
} }