Skip to content

Conversation

@sundy-li
Copy link
Member

@sundy-li sundy-li commented Dec 9, 2025

I hereby agree to the terms of the CLA available at: https://docs.databend.com/dev/policies/cla/

Summary

fix(query): fix stale indices in process_or

selector keeps stale indices when enable_selector_executor is on and the predicate tree contains OR branches (your predicate has multiple ORs plus NOT EXISTS/EXISTS). Once the OR branch switches from SelectStrategy::All to
SelectStrategy::False, count still reflects the number of rows considered earlier, so we can end up reading false_selection entries that were never written in this block and still carry row ids from the previous block, which are out
of range for the current chunk.

Tests

  • Unit Test
  • Logic Test
  • Benchmark Test
  • No Test - Explain why

Type of change

  • Bug Fix (non-breaking change which fixes an issue)
  • New Feature (non-breaking change which adds functionality)
  • Breaking Change (fix or feature that could cause existing functionality not to work as expected)
  • Documentation Update
  • Refactoring
  • Performance Improvement
  • Other (please describe):

This change is Reviewable

@github-actions github-actions bot added the pr-bugfix this PR patches a bug in codebase label Dec 9, 2025
@wubx wubx added the ci-cloud Build docker image for cloud test label Dec 10, 2025
@github-actions
Copy link
Contributor

Docker Image for PR

  • tag: pr-19085-9c9732b-1765338738

note: this image tag is only available for internal use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-cloud Build docker image for cloud test pr-bugfix this PR patches a bug in codebase

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants