fix issue/42559381,query result incorrect bug

This commit is contained in:
obdev
2022-07-05 16:15:47 +08:00
committed by wangzelin.wzl
parent b056d5d732
commit 031989c299
2 changed files with 3 additions and 8 deletions

View File

@ -1436,13 +1436,8 @@ int ObExprGeneratorImpl::visit(ObAggFunRawExpr& expr)
} else if (OB_FAIL(sql_expr_->add_expr_item(item, &expr))) {
LOG_WARN("failed to add expr item", K(ret));
} else {
if (T_FUN_JSON_OBJECTAGG == expr.get_expr_type()) {
aggr_expr->set_real_param_col_count(expr.get_real_param_count());
aggr_expr->set_all_param_col_count(expr.get_param_count());
} else {
aggr_expr->set_real_param_col_count(1);
aggr_expr->set_all_param_col_count(1);
}
aggr_expr->set_real_param_col_count(expr.get_real_param_count());
aggr_expr->set_all_param_col_count(expr.get_param_count());
if (OB_SUCCESS == ret &&
(T_FUN_GROUP_CONCAT == expr.get_expr_type() || T_FUN_GROUP_RANK == expr.get_expr_type() ||
T_FUN_GROUP_DENSE_RANK == expr.get_expr_type() || T_FUN_GROUP_PERCENT_RANK == expr.get_expr_type() ||