Skip to content

Commit ac2cc17

Browse files
committed
fix(cubesql): Cannot read properties of undefined (reading 'preAggregation') with enabled SQL push down
1 parent 7cb1229 commit ac2cc17

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/cubejs-schema-compiler/src/adapter/BaseQuery.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ export class BaseQuery {
468468
if (!this.options.preAggregationQuery && !this.ungrouped) {
469469
preAggForQuery =
470470
this.preAggregations.findPreAggregationForQuery();
471-
if (this.options.disableExternalPreAggregations && preAggForQuery.preAggregation.external) {
471+
if (this.options.disableExternalPreAggregations && preAggForQuery && preAggForQuery.preAggregation.external) {
472472
preAggForQuery = undefined;
473473
}
474474
}

0 commit comments

Comments
 (0)