Hello Peter Rozsa, Steve Carlin, Impala Public Jenkins,

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24440

to look at the new patch set (#3).

Change subject: IMPALA-14993: Fix count star optimization incorrectly 
activating without count(*)
......................................................................

IMPALA-14993: Fix count star optimization incorrectly activating without 
count(*)

The Iceberg V2 count star optimization (optimizePlainCountStarQueryV2)
activated for queries like 'SELECT 1 FROM iceberg_table' when the table
had delete files, causing incorrect results (missing rows). The
validation loop rejected non-count(*)/non-constant expressions but never
verified that at least one count(*) was actually present.

Added a hasCountStarFunc guard matching the existing V1 method's logic.
Also added regression tests for both Iceberg V2 and V3 (Deletion Vector)
tables.

Testing:
 * Added V2 regression test with SELECT 1 on table with position deletes
 * Added V3 test covering count(*) optimization and the IMPALA-14993 fix

Change-Id: I8eb13aecef6d3b7460f7201dce6e03d6f3de303a
Assisted-by: Claude Opus 4.6 <[email protected]>
---
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M 
testdata/workloads/functional-query/queries/QueryTest/iceberg-v2-plain-count-star-optimization.test
A 
testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-plain-count-star-optimization.test
M tests/query_test/test_iceberg.py
4 files changed, 86 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/40/24440/3
--
To view, visit http://gerrit.cloudera.org:8080/24440
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I8eb13aecef6d3b7460f7201dce6e03d6f3de303a
Gerrit-Change-Number: 24440
Gerrit-PatchSet: 3
Gerrit-Owner: Zoltan Borok-Nagy <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Peter Rozsa <[email protected]>
Gerrit-Reviewer: Steve Carlin <[email protected]>

Reply via email to