HIVE-29503: Prevent Join cardinality overestimation of joins with NDV(0) columns#6356
Open
konstantinb wants to merge 7 commits intoapache:masterfrom
Open
HIVE-29503: Prevent Join cardinality overestimation of joins with NDV(0) columns#6356konstantinb wants to merge 7 commits intoapache:masterfrom
konstantinb wants to merge 7 commits intoapache:masterfrom
Conversation
…ng the join product row count with an NDV of 0
konstantinb
commented
Mar 23, 2026
| input vertices: | ||
| 1 Map 2 | ||
| Statistics: Num rows: 4 Data size: 1184 Basic stats: COMPLETE Column stats: COMPLETE | ||
| Statistics: Num rows: 2 Data size: 325 Basic stats: COMPLETE Column stats: NONE |
Contributor
Author
There was a problem hiding this comment.
at the moment. NDV of datetime/timestamp columns is not being assigned to colstats even if available. Changing that will make this estimate better; however, doing impacts over 100 .out files so perhaps doing so belongs to a separate story?
Contributor
Author
these were introduced by #6361 |
|
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.



What changes were proposed in this pull request?
HIVE-29503: Use the fallback of half the number of rows when estimating the join product row count with an NDV of 0
Why are the changes needed?
Does this PR introduce any user-facing change?
How was this patch tested?