hubgeter opened a new pull request, #68144:
URL: https://github.com/apache/doris/pull/68144

   ### What problem does this PR solve?
   
   Issue Number: None
   
   Related PR: #68137
   
   Problem Summary:
   
   On branch-4.1, a Variant predicate that follows an unsafe conjunct can prune 
Parquet row groups and pages before that conjunct is evaluated, so its error is 
lost:
   
   ```sql
   SELECT COUNT(*) FROM iceberg_tbl
   WHERE assert_true(id != 1, 'barrier') AND v['n'] > 5000;
   -- returns 0 instead of failing with 'barrier'
   ```
   
   Ordinary metadata pruning only uses the conjuncts before the first unsafe 
one (`metadata_pruning_safe_conjunct_count`). The shredded Variant row-group 
statistics, page-index pruning and `has_variant_shredded_filter` still read 
every conjunct. This PR restricts them to the same prefix, matching master.
   
   As on master, CAST is not safe to pre-execute, so Variant typed-leaf 
predicates no longer prune row groups or pages. `test_iceberg_variant_read` 
takes the test updates from #68137 and adds the error barrier case from master.
   
   ### Release note
   
   Fix Iceberg Variant queries returning a result instead of an error when a 
Variant predicate follows an error-raising expression such as `assert_true`.
   
   ### Check List (For Author)
   
   - Test
       - [x] Regression test
       - [x] Unit Test
       - [ ] Manual test (add detailed scripts or steps below)
       - [ ] No need to test or manual test. Explain why:
           - [ ] This is a refactor/code format and no logic has been changed.
           - [ ] Previous test can cover this change.
           - [ ] No code files have been changed.
           - [ ] Other reason
   
   - Behavior changed:
       - [ ] No.
       - [x] Yes. Variant typed-leaf predicates no longer prune Parquet row 
groups or pages, as on master.
   
   - Does this need documentation?
       - [x] No.
       - [ ] Yes.
   
   ### Check List (For Reviewer who merge this PR)
   
   - [ ] Confirm the release note
   - [ ] Confirm test cases
   - [ ] Confirm document
   - [ ] Add branch pick label
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to