Repository navigation
Backport #99504 to 25.12: Fix NOT_FOUND_COLUMN_IN_BLOCK when text index predicate is referenced in SELECT - #99631
Merged
Merged
Conversation
…ndex predicate is referenced in SELECT
Contributor
|
Workflow [BackportPR], commit [860ab90] Summary: ✅ |
…n text index predicate is referenced in SELECT" This reverts commit 57801bd.
… optimization The original backport brought the entire master version of `optimizeDirectReadFromTextIndex.cpp` which depends on `Interpreters/ITokenizer.h` that doesn't exist on the 25.12 branch. Instead, apply the minimal fix: when `replaceNodes` substitutes a text-search function node with a virtual column input, add an alias to preserve the original column name. This ensures downstream steps (e.g. ExpressionStep for SELECT) that reference the predicate by its original name can still find it in the block. #99631 Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
The backport of PR #99504 added an alias in replaceNodes() to preserve original column names for downstream steps, fixing NOT_FOUND_COLUMN_IN_BLOCK. This alias causes EXPLAIN to show original expression names instead of __text_index_* virtual column names in Filter/Prewhere column output. Update all affected tests to check for __text_index virtual column presence in EXPLAIN actions output instead of checking Filter column names, matching the approach used in the original master PR. Also add missing SET allow_experimental_full_text_index = 1 to the new 04039_text_index_direct_read_select_alias test. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Original pull-request #99504
Cherry-pick pull-request #99617
This pull-request is a last step of an automated backporting.
Treat it as a standard pull-request: look at the checks and resolve conflicts.
Merge it only if you intend to backport changes to the target branch, otherwise just close it.
The PR source
The PR is created in the CI job
Version info
25.12.9.51