This is an automated email from the ASF dual-hosted git repository. yiguolei pushed a commit to branch branch-2.0 in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-2.0 by this push: new 83ca2ad1822 [fix](read) fix unexpected overflow of uninitialized column data in VStatisticsIterator::next_batch (#29141) (#29166) 83ca2ad1822 is described below commit 83ca2ad18228840abcc3b4060c8dcd571e470ca8 Author: TengJianPing <18241664+jackte...@users.noreply.github.com> AuthorDate: Wed Dec 27 20:51:37 2023 +0800 [fix](read) fix unexpected overflow of uninitialized column data in VStatisticsIterator::next_batch (#29141) (#29166) --- be/src/vec/olap/vgeneric_iterators.cpp | 2 +- regression-test/data/datatype_p0/decimalv3/test_decimalv3.out | 6 ++++++ regression-test/suites/datatype_p0/decimalv3/test_decimalv3.groovy | 5 +++++ 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/be/src/vec/olap/vgeneric_iterators.cpp b/be/src/vec/olap/vgeneric_iterators.cpp index 7431d2f7582..4b33da03643 100644 --- a/be/src/vec/olap/vgeneric_iterators.cpp +++ b/be/src/vec/olap/vgeneric_iterators.cpp @@ -75,7 +75,7 @@ Status VStatisticsIterator::next_batch(Block* block) { if (_push_down_agg_type_opt == TPushAggOp::COUNT) { size = std::min(_target_rows - _output_rows, MAX_ROW_SIZE_IN_COUNT); for (int i = 0; i < block->columns(); ++i) { - columns[i]->resize(size); + columns[i]->insert_many_defaults(size); } } else { for (int i = 0; i < block->columns(); ++i) { diff --git a/regression-test/data/datatype_p0/decimalv3/test_decimalv3.out b/regression-test/data/datatype_p0/decimalv3/test_decimalv3.out index 0482cc4164a..88c58e41503 100644 --- a/regression-test/data/datatype_p0/decimalv3/test_decimalv3.out +++ b/regression-test/data/datatype_p0/decimalv3/test_decimalv3.out @@ -5,6 +5,12 @@ -- !decimalv3 -- 100.00000000000000000000 +-- !decimalv3_view1 -- +1 + +-- !decimalv3_view2 -- +1 + -- !aEb_test1 -- 0 diff --git a/regression-test/suites/datatype_p0/decimalv3/test_decimalv3.groovy b/regression-test/suites/datatype_p0/decimalv3/test_decimalv3.groovy index 2b72c36867b..c8ce219b141 100644 --- a/regression-test/suites/datatype_p0/decimalv3/test_decimalv3.groovy +++ b/regression-test/suites/datatype_p0/decimalv3/test_decimalv3.groovy @@ -27,6 +27,11 @@ suite("test_decimalv3") { qt_decimalv3 "select * from test5_v" qt_decimalv3 "select cast(a as decimalv3(12,10)) * cast(b as decimalv3(18,10)) from test5" + qt_decimalv3_view1 "select count(*) from test5_v;" + + sql "drop view if exists test5_v2" + sql "create view test5_v2 (amout) as select cast(a as decimalv3(18,6)) from test5" + qt_decimalv3_view2 "select count(*) from test5_v2;" sql "set experimental_enable_nereids_planner =false;" qt_aEb_test1 "select 0e0;" --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org