supprt sql_quote_show_create variable in mysql mode

This commit is contained in:
ChangerR
2023-07-13 10:12:23 +00:00
committed by ob-robot
parent 6810df627b
commit a03af93f4d
15 changed files with 598 additions and 348 deletions

View File

@ -45,8 +45,10 @@ class ObRawExprPrinter
#define PRINT_IDENT(ident_str) \
do { \
if (OB_SUCC(ret) && OB_FAIL(ObSQLUtils::print_identifier( \
buf_, buf_len_, (*pos_), print_params_.cs_type_, ident_str))) { \
if (OB_SUCC(ret) && OB_FAIL(ObSQLUtils::print_identifier(buf_, buf_len_, (*pos_), \
print_params_.cs_type_, \
ident_str, \
lib::is_oracle_mode()))) { \
LOG_WARN("fail to print ident str", K(ret), K(ident_str)); \
} \
} while(0)
@ -89,6 +91,13 @@ class ObRawExprPrinter
DATA_PRINTF(" "); \
PRINT_QUOT;
#define PRINT_IDENT_WITH_QUOT(ident_str) \
do { \
PRINT_QUOT; \
PRINT_IDENT(ident_str); \
PRINT_QUOT; \
} while (0)
// cast函数在parse阶段用到这两个宏, 但定义在sql_parse_tab.c中
// cast函数功能不完善,beta之前不会修改, 先定义在这里
// TODO@nijia.nj