Repository navigation
Add column-group statistics - #118
Open
chopradish wants to merge 5 commits into
Open
chopradish wants to merge 5 commits into
chopradish wants to merge 5 commits into
Conversation
chopradish
force-pushed
the
ac/multi-col-hll
branch
from
November 2, 2026 22:10
234d5ad to
1d32ad3
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files
🚀 New features to boost your workflow:
|
chopradish
force-pushed
the
ac/multi-col-hll
branch
from
November 10, 2026 17:37
1d32ad3 to
1d4b7ea
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.
Problem
Single-column distinct-value estimates cannot capture correlations between grouping keys or composite join keys. As a result, cardinality estimates can be substantially wrong for correlated multi-column data.
Summary of changes
Collect query-local HyperLogLog statistics for bounded logical-schema column prefixes and store them as validated column-group statistics. Extend cardinality estimation to use compatible joint NDVs for grouping and direct composite inner joins, with single-column fallbacks for uncovered keys.
Design
Statistics are keyed by logical schema ordinals and looked up as sets, independent of predicate or grouping-key order. Groups are used only when their population and null-handling metadata are compatible with the input; classic HLL remains an NDV synopsis and is not used for set-intersection estimation.
Stack created with GitHub Stacks CLI • Give Feedback 💬