Fix a bug when create view with having clause

This commit is contained in:
xianyu-w
2023-08-22 03:44:38 +00:00
committed by ob-robot
parent 5e31c2aa1c
commit 7b6f4dae66
2 changed files with 3 additions and 2 deletions

View File

@ -102,7 +102,8 @@ int ObRawExprPrinter::print(ObRawExpr *expr)
&& scope_ != T_GROUP_SCOPE
&& scope_ != T_WHERE_SCOPE
&& scope_ != T_NONE_SCOPE
&& scope_ != T_ORDER_SCOPE) {
&& scope_ != T_ORDER_SCOPE
&& (scope_ == T_HAVING_SCOPE && lib::is_mysql_mode())) {
//expr is a alias column ref
//alias column target list
PRINT_IDENT_WITH_QUOT(expr->get_alias_column_name());