-
Notifications
You must be signed in to change notification settings - Fork 1.8k
fix(schema-compiler): Use join paths from pre-aggregation declaration instead of building join tree from scratch #9471
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
b38d3b6
to
fd7e96a
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #9471 +/- ##
===========================================
- Coverage 80.54% 59.07% -21.47%
===========================================
Files 382 153 -229
Lines 96521 13017 -83504
Branches 2192 2202 +10
===========================================
- Hits 77739 7690 -70049
+ Misses 18471 5014 -13457
- Partials 311 313 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍🏻
fd7e96a
to
9698ca6
Compare
… instead of building join tree from scratch (#9431) Without this pre-aggregatoin declaration would build a list of members, and build join tree from scratch. New join tree could be different, and pre-aggregation would contain incorrect data. Add join hints to member adapters, to build join tree with proper members. This is more of a hack than proper solution: join tree would still disallow to have same cube twice with different join paths. Just adding extra join hints on query level does not work because of FKQA and multiplication check in subqueries: we have to know join path for every member, so it should be either explicit or unambigous _for each member_. Join tree from query is still not included in pre-aggregation matching, so user would have to manually ensure that views and pre-aggregations both match each other and does not produce false matches (cherry picked from commit aea3a6c)
…e join paths tests
…ncy between CubeSymbols and BaseQuery
9698ca6
to
2bb6df8
Compare
Check List
Description of Changes Made (if issue reference is not provided)
Take 2 for #9431, now with more tests and fixes in pre-aggregations matching
Without this pre-aggregatoin declaration would build a list of members, and build join tree from scratch. New join tree could be different, and pre-aggregation would contain incorrect data.
Add join hints to member adapters, to build join tree with proper members. This is more of a hack than proper solution: join tree would still disallow to have same cube twice with different join paths.
Just adding extra join hints on query level does not work because of FKQA and multiplication check in subqueries: we have to know join path for every member, so it should be either explicit or unambigous for each member.
Join tree from query is still not included in pre-aggregation matching, so user would have to manually ensure that views and pre-aggregations both match each other and does not produce false matches
For now, only pre-aggregation itself respects join paths, but pre-aggregation matching does same as before: strips join path from pre-aggregation references and compares members directly.