Fix #1034 for SET @@sql_mode (#1065)

This commit is contained in:
程序员小王(troy)
2023-04-03 16:53:52 +08:00
committed by GitHub
parent 82d1996bde
commit eedd6feff1

View File

@ -1517,8 +1517,11 @@ int ObSqlModeVar::do_check_and_convert(ObExecContext &ctx,
LOG_ERROR("fail to get varchar", K(ret), K(in_val));
}
} else {
ret = OB_ERR_UNEXPECTED;
LOG_ERROR("unexpected type", K(ret), K(in_val));
ret = OB_ERR_WRONG_VALUE_FOR_VAR;
int log_ret = OB_SUCCESS;
if (OB_SUCCESS != (log_ret = log_err_wrong_value_for_var(ret, in_val))) {
LOG_ERROR("fail to log error", K(ret), K(log_ret), K(in_val));
}
}
ObString val_without_space = str_val.trim_space_only();
if (OB_FAIL(ret)) {