[xml bugfix] 1. xmltype empty variable problem under pl 2. xmlelement anti-spelling label case problem

This commit is contained in:
obdev
2023-06-13 09:42:25 +00:00
committed by ob-robot
parent 68af9e5cf9
commit 635b221288
2 changed files with 9 additions and 2 deletions

View File

@ -1772,6 +1772,13 @@ int ObSqlParameterization::mark_tree(ParseNode *tree ,SqlInfo &sql_info)
if (OB_FAIL(mark_args(node[1], mark_arr, ARGS_NUMBER_THREE, sql_info))) {
SQL_PC_LOG(WARN, "fail to mark arg", K(ret));
}
} else if (0 == func_name.case_compare("xmlserialize")
&& (10 == node[1]->num_child_)) {
const int64_t ARGS_NUMBER_TEN = 10;
bool mark_arr[ARGS_NUMBER_TEN] = {1, 0, 1, 1, 1, 1, 1, 1, 1, 1}; //0表示参数化, 1 表示不参数化
if (OB_FAIL(mark_args(node[1], mark_arr, ARGS_NUMBER_TEN, sql_info))) {
SQL_PC_LOG(WARN, "fail to mark weight_string arg", K(ret));
}
}else if (0 == func_name.case_compare("weight_string")
&& (5 == node[1]->num_child_)) {
const int64_t ARGS_NUMBER_FIVE = 5;

View File

@ -4539,10 +4539,10 @@ int ObRawExprPrinter::print_xml_element_expr(ObSysFunRawExpr *expr)
if (OB_SUCC(ret) && format_type == 0) {
if (buf_[cur_pos] == '\'') {
buf_[cur_pos] = ' ';
buf_[cur_pos] = '"';
}
if (buf_[new_pos - 1] == '\'') {
buf_[new_pos - 1] = ' ';
buf_[new_pos - 1] = '"';
}
}