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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
manoj_0911
Advocate V
Advocate V

Compare data between current period and last period for multiple metrics & multiple date presets

Hi Experts,

 

I am working on a Power BI report where I need to compare values between the current period and the previous period. The challenge is:

  • I have multiple metrics (e.g., Total calls, AVG Queue Time, Self Served %, etc.).

  • I also need to allow the user to select from multiple date presets ( Today vs Yesterday
    , Last 7 Days vs Previous 7, This Week vs Last Week, This Month vs Last Month, This Quarter vs Last Qtr, This Year vs Last Year, Year to Date vs Prev YTD, Rolling N Days)

  • The comparison should dynamically work for whichever metric and date range the user selects.

Could you please suggest the best DAX approach or modeling technique to handle this scenario?

  • Should I create separate measures for each date preset (Today vs Yesterday
    , Last 7 Days vs Previous 7, This Week vs Last Week, This Month vs Last Month, This Quarter vs Last Qtr, This Year vs Last Year, Year to Date vs Prev YTD, Rolling N Days)?

  • Or is there a more scalable and reusable method (maybe using calculation groups or dynamic measures)?

  • If possible, examples of DAX or links to best practices would be very helpful.

Thanks in advance!

1 ACCEPTED SOLUTION

Hi @manoj_0911 ,
Please check out this articles to know more about calculation groups:
Create calculation groups in Power BI - Power BI | Microsoft Learn

 

Calculation groups in Analysis Services tabular models | Microsoft Learn

 

I hope this information helps. Please do let us know if you have any further queries.
Thank you

View solution in original post

6 REPLIES 6
v-nmadadi-msft
Community Support
Community Support

Hi @manoj_0911 

May I check if this issue has been resolved? If not, Please feel free to contact us if you have any further questions.


Thank you

v-nmadadi-msft
Community Support
Community Support

Hi @manoj_0911 

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions.


Thank you.

Nabha-Ahmed
Kudo Commander
Kudo Commander

 

You can handle this scenario more efficiently using Calculation Groups in Power BI (via Tabular Editor).
Instead of creating separate measures for each comparison (Today vs Yesterday, Last 7 Days vs Previous 7, etc.), build a Time Intelligence Calculation Group that dynamically applies the right date logic based on a user-selected “Date Preset” (like Day, Week, Month, Quarter, Year).

This approach is scalable, reusable, and easier to maintain, since all your metrics (Total Calls, Avg Queue Time, etc.) can automatically adapt to the selected period.

For reference, check:
 Microsoft Docs – Calculation Groups
 SQLBI – Dynamic Time Intelligence

 

Thanks

Hi, when I click the links, they do not take me to the page; they appear static or are not working. Could you please check?

Hi @manoj_0911 ,
Please check out this articles to know more about calculation groups:
Create calculation groups in Power BI - Power BI | Microsoft Learn

 

Calculation groups in Analysis Services tabular models | Microsoft Learn

 

I hope this information helps. Please do let us know if you have any further queries.
Thank you

AnkitaaMishra
Super User
Super User

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors