cube
cube copied to clipboard
Pre-aggregations for a rolling-window measure
Description
I have a cube with an unbounded rolling-window measure. I would like to have pre-aggregation support for this type of measures.
Pre-agg
preAggregations: {
myRollup: {
type: `rollup`,
measureReferences: [myMeasure],
timeDimensionReference: eventDate,
granularity: `day`
},
Measure
measures: {
myMeasure: {
type: `avg`,
sql: `${value}`,
rollingWindow: {
trailing: `unbounded`
}
},
Query
Note: This query should trigger the pre-aggregation, but does not.
{
"measures":[
"MyCube.myMeasure"
],
"timeDimensions":[
{
"dimension":"MyCube.eventDate",
"granularity":"day",
"dateRange":"Last%20month"
}
]
}
@atotev Thanks for posting this!
@paveltiunov I ran into this issue recently and it became a roadblock for how my team was planning to use Cube.js with a particular cube definition containing rollingWindow. My team and I are interested in helping, but could use some guidance on what would be involved / where to look for doing so.. thanks!
Do we have any solution to this problem?? I am facing the same problem.
Hi all,
Just as an update, this issue is on our roadmap and we hope to have something ready this quarter.
What's the current ETA on resolution for this?
I can't create pre-aggregation tables for rollingwindow measure types using cube 0.28.64 Any updates regarding this?
Hey @hassankhan, was this still on the roadmap? Cheers!
Implemented in latest versions.