Skip to content

Commit 3a52ed9

Browse files
committed
fix buildRollupJoin
1 parent 8f7acc7 commit 3a52ed9

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/cubejs-schema-compiler/src/adapter/PreAggregations.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -996,7 +996,11 @@ export class PreAggregations {
996996

997997
// TODO join hints?
998998
const existingJoins = preAggObjsToJoin
999-
.map(p => this.resolveJoinMembers(this.query.joinGraph.buildJoin(this.cubesFromPreAggregation(p))!))
999+
.map(p => this.resolveJoinMembers(
1000+
this.query.joinGraph.buildJoin(
1001+
this.collectJoinHintsFromRollupReferences(p.references).concat(this.cubesFromPreAggregation(p))
1002+
)!
1003+
))
10001004
.flat();
10011005

10021006
const nonExistingJoins = targetJoins.filter(target => !existingJoins.find(

0 commit comments

Comments
 (0)