fix 3-stage agg wrong result && fix aggr ignore error code && fix int_cell_str sanity core
This commit is contained in:
2
deps/oblib/src/rpc/obmysql/ob_mysql_util.cpp
vendored
2
deps/oblib/src/rpc/obmysql/ob_mysql_util.cpp
vendored
@ -363,7 +363,7 @@ int ObMySQLUtil::int_cell_str(
|
||||
int64_t bytes_to_store_len = get_number_store_len(length);
|
||||
if (OB_UNLIKELY(pos + bytes_to_store_len + ffi.length() > len)) {
|
||||
ret = OB_SIZE_OVERFLOW;
|
||||
} else if (zero_cnt > 0 && OB_UNLIKELY(pos + bytes_to_store_len + zero_cnt > len)) {
|
||||
} else if (zero_cnt > 0 && OB_UNLIKELY(pos + bytes_to_store_len + zero_cnt + ffi.length() > len)) {
|
||||
ret = OB_SIZE_OVERFLOW;
|
||||
} else {
|
||||
MEMCPY(buf + pos + bytes_to_store_len, ffi.ptr(), ffi.length());
|
||||
|
||||
@ -1344,7 +1344,7 @@ int ObAggregateProcessor::collect_for_empty_set()
|
||||
if (OB_ISNULL(aggr_info.expr_)) {
|
||||
ret = OB_ERR_UNEXPECTED;
|
||||
LOG_WARN("expr node is null", K(ret));
|
||||
} else if (aggr_info.is_implicit_first_aggr()) {
|
||||
} else if (aggr_info.is_implicit_first_aggr() && aggr_stage_ != ObThreeStageAggrStage::THIRD_STAGE) {
|
||||
set_expr_datum_null(aggr_info.expr_);
|
||||
} else {
|
||||
switch (aggr_info.get_expr_type()) {
|
||||
@ -2297,7 +2297,9 @@ int ObAggregateProcessor::process_aggr_batch_result(
|
||||
aggr_cell.set_is_evaluated(true);
|
||||
}
|
||||
}
|
||||
ret = approx_count_calc_batch(*llc_bitmap, param_exprs, selector);
|
||||
if (OB_SUCC(ret)) {
|
||||
ret = approx_count_calc_batch(*llc_bitmap, param_exprs, selector);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case T_FUN_APPROX_COUNT_DISTINCT_SYNOPSIS_MERGE: {
|
||||
|
||||
Reference in New Issue
Block a user