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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
maurcoll
Helper III
Helper III

Previous Quarter Comparison

Hi

i need to produce the below table where it is comparing the previous 2 complete quarters. In the below example it would be financial Q4 compared to financial Q3 as we are currently in financial Q1. Next quarter it would be Financial Q1 compared to Financial Q4. I have a date calendar where the financial quarter number is stored as a number and a financial year column also stored as a number.

 Last QuarterPrevious Quarter% Difference
Total Sales1234234510%

 

Thank you for your help

1 ACCEPTED SOLUTION

Hi

 

I ended up using the previousquarter function which has worked. I just need to add the Quarter Year into a slicer

View solution in original post

6 REPLIES 6
v-echaithra
Community Support
Community Support

Hi @maurcoll ,

May I ask if you have gotten this issue resolved?

 

If it is solved, please mark the helpful reply or share your solution and accept it as solution, it will be helpful for other members of the community who have similar problems as yours to solve it faster.

 

Regards,

Chaithra E.

v-echaithra
Community Support
Community Support

Hi @maurcoll ,

We wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.

 

Regards,
Chaithra.

Hi

 

I ended up using the previousquarter function which has worked. I just need to add the Quarter Year into a slicer

Hi @maurcoll ,

Please accept the solution that have resolved your issue, as it would be helpful for other community members.

Regards,
Chaithra E.

pankajnamekar25
Super User
Super User

Hello @maurcoll 

 

please try this measure

 

Last Completed YearQuarter =

VAR CurrentYear = MAX('Date'[FinancialYear])

VAR CurrentQuarter = MAX('Date'[FinancialQuarter])

-- Completed quarter is always one before the current

RETURN

IF(CurrentQuarter = 1,

    (CurrentYear - 1) * 10 + 4, -- Q4 of previous year

    CurrentYear * 10 + (CurrentQuarter - 1)

)

 

Thanks,
 Pankaj Namekar | LinkedIn

If this solution helps, please accept it and give a kudos (Like), it would be greatly appreciated.

Hi

I'm getting a value of 20283, my calendar table goes forward to 2028.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.