Project RecordBatch before evaluating case#18275
Closed
pepijnve wants to merge 46 commits intoapache:mainfrom
Closed
Project RecordBatch before evaluating case#18275pepijnve wants to merge 46 commits intoapache:mainfrom
case#18275pepijnve wants to merge 46 commits intoapache:mainfrom
Conversation
Contributor
Author
|
This PR builds on the work done in #18152 and will be marked ready for review once/if that PR lands. |
d3cd191 to
70024ad
Compare
70024ad to
11028de
Compare
- Use usize::MAX as null marker instead of zero - Introduce `ResultState` enum - Make diagrams more representative - Extend documentation of `merge`
5b86121 to
b751a08
Compare
b751a08 to
e17be32
Compare
…d potential programming errors
e17be32 to
6691bc6
Compare
# Conflicts: # datafusion/sqllogictest/test_files/case.slt
6691bc6 to
d7e49c5
Compare
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.
Which issue does this PR close?
SELECT *, CASE ... END#18056Rationale for this change
When
CaseExprneeds to evaluate aPhysicalExprfor a subset of the rows of the inputRecordBatchit will first filter the record batch using a selection vector. This filter steps filters all columns of theRecordBatch, including ones that may not be accessed by thePhysicalExpr. For wide (many columns) record batches and narrow expressions (few column references) it can be beneficial to project the record batch first to reduce the amount of wasted filtering work.What changes are included in this PR?
Are these changes tested?
Are there any user-facing changes?
No