Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
mhumpher
New Member

Direct Query with Calculation Groups

I have a composite model that I'm adding calculation group to. It includes a fact table of sales which includes an application submission date and a paid date. Alongside this I have a date table which are related. I've added a calculation group that can switch between using the submission date and the paid date to calculate measures. I also have a date aggregation calculation group that looks at dates weekly, monthly and on a rolling 4 week. 

If I do not filter the data by anything else, I can use both calculation groups and I get a full set of data. When I add a filter, for example on product in another dimension table, suddenly the visual only gives me a partial set of data. If I remove the date aggregations calculation group and keep the filter, I get a full set of data again. 

When I compare the queries generated from the Performance Analyzer, the main difference is that the DirectQuery section with the date aggregation creates a variable with a seemingly arbitrary list of date from the date table.

How can I prevent or work around this behavior?

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@mhumpher , date aggregations mean grouping data by date, try not to use date hierarchy. 

if date aggregations mean implicit measure sum of date, without measure, that will not work well with calculation group

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@mhumpher , date aggregations mean grouping data by date, try not to use date hierarchy. 

if date aggregations mean implicit measure sum of date, without measure, that will not work well with calculation group

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.