We have created a reflection on one of our tables. No joins, no nothing, just a pure aggregate reflection on certain columns.
If I query the table without datetime parameters (“ido” in our case) the reflection is used and the query is accelerated. However, if I include the “ido” datetime WHERE clause, the query is not accelerated.
Granularity is set to “day”, and as you can see from the profiles, the “ido” datetime column is part of the aggregation.
Same thing happened, with a different set of data… I am sure I am missing something but some help would be appreciated.
I attached both profiles for the properly accelerated and the unaccelerated query with datetime filter.
I might have an answer… I changed the granularity from “day” to “original” for the Aggregate Reflection on the Advanced Tab and it looks like its working - the queries are Accelerated properly.
Another problem comes, when I have the Dataset connected to Superset, there is no “Time Grain” option for my Timestamp columns… Since I kept the “original” value at the reflection, my charts are showing down to the “second” scale.
It is the case for the other datetime columns as well, where the reflection is set to “day” (however in these cases the Acceleration is not working).
@balaji.ramaswamy Should I open a separate discussion on the Superset - Time Grain issue?