Virtual Schema Pushdown: Partial filter pushdown for queries with aggregations
Details
| Detail name | Value |
|---|---|
| Changelog Number | 6657 |
| Type | Improvement |
| Status | Resolved |
| Fix Versions | Exasol 6.0.12 |
| Resolution Date | 2018-08-22 |
Pre-Improvement Behavior
In the case that a query including virtual schema objects
- contains an aggregation which cannot be pushed down (eg. because it's applied to join of local and remote table)
- multiple WHERE conditions (combined through AND), where a subset applies to the virtual table, and others to a joined table
Then in the past the behavior was:
- do not push down any filter to the virtual table, because either all filters or no filters had to be pushed down in case there is an aggregation in the surrounding query
Improvement
The new behavior is: All filters applying to the virtual table are pushed down (because filters must be applied before aggregation anyway)
Example:
In this example, the filter f.type = 1 will be pushed down after this improvement:
SELECT p.age, sum(f.val) FROM virtualschema.facts f JOIN localschema.people p ON f.people_id = p.id WHERE p.age < 18 and f.type = 1 group by p.age;