Forum Discussion
Manage aggregations multiple fact tables DirectLake over OneLake
- 11 months ago
Hello Jacek,
In aggregatinos tables, the user cannot force which table is used. If they select “Month” in a slicer, the engine may still query the daily table if the visual structure doesn’t match the aggregation definition.
Aggregations are designed for performance optimization, not user-driven logic. But in calculation groups there is explicit user control, the slicer dictates exactly which table is queried.
Best,
Anıl
Hello jaryszek ,
You can create a composite model with calculation groups. For this, you need Tabular Editor (or another TOM/ALM-based tool) to add a calculation group into your model.
After that you can create a disconnected parameter table:
Granularity = DATATABLE(
"Level", STRING,
{
{"Daily"},
{"Monthly"}
}
)
And then you should define a calculation group like "Granularity Selection" with a calculation item like:
Selected Value =
SWITCH(
SELECTEDVALUE(Granularity[Level]),
"Daily", CALCULATE(SUM(fct_table_daily[Amount])),
"Monthly", CALCULATE(SUM(fct_table_monthly[Amount]))
)
If this solved your issue, please mark it as the accepted solution. ✅
Hello,
why this is better than Aggregations tables?
Best,
Jacek
- anilelmastasi11 months ago
Super User
Hello Jacek,
In aggregatinos tables, the user cannot force which table is used. If they select “Month” in a slicer, the engine may still query the daily table if the visual structure doesn’t match the aggregation definition.
Aggregations are designed for performance optimization, not user-driven logic. But in calculation groups there is explicit user control, the slicer dictates exactly which table is queried.
Best,
Anıl
- jaryszek11 months ago
Super User
thank you.
This is great answer!- anilelmastasi11 months ago
Super User
You are welcome Jacek, could you please accept as solution 🙂