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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
sanghamitra123
New Member

QoQ comparison of last two years

Hi Everyone,

 

Need your help as i am new to Power Bi. I need to compare the QoQ for two years, lets say Q1 2017 Vs Q1 2018. so when i drill down this comparision, it should be Month 2017 Vs Month 2018 and further week 2017 Vs week 2018. Pls let me know how to do this. Appreciate an early reply, since its very urgent for me.

 

Thank you.

1 ACCEPTED SOLUTION
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @sanghamitra123,

 

It seems that you want to compare the QoQ for two years.

 

Here is my sample. If you create two measures like below, then you could get the compare chart for QoQ for two years.

2017 Qtr = CALCULATE(SUM(Table1[Sales]),FILTER('Table1',YEAR('Table1'[Date])=YEAR(MIN('Table1'[Date]))))

2018 Qtr = CALCULATE(SUM(Table1[Sales]),FILTER('Table1',YEAR('Table1'[Date])=YEAR(MIN('Table1'[Date]))+1))

Capture.PNG

 

In addition, you could have a reference of this video for Quarter On Quarter Sales Trends In Power BI - DAX Formula.

 

If you still need help, please share some data sample and your desired output so that we could help further on it.

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @sanghamitra123,

 

It seems that you want to compare the QoQ for two years.

 

Here is my sample. If you create two measures like below, then you could get the compare chart for QoQ for two years.

2017 Qtr = CALCULATE(SUM(Table1[Sales]),FILTER('Table1',YEAR('Table1'[Date])=YEAR(MIN('Table1'[Date]))))

2018 Qtr = CALCULATE(SUM(Table1[Sales]),FILTER('Table1',YEAR('Table1'[Date])=YEAR(MIN('Table1'[Date]))+1))

Capture.PNG

 

In addition, you could have a reference of this video for Quarter On Quarter Sales Trends In Power BI - DAX Formula.

 

If you still need help, please share some data sample and your desired output so that we could help further on it.

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi Cherry,

 

I managed to get the chart as below, thanks a lot. Pls let me know if there is a way to drill down further into months and weeks in the same chart, comparing two years (Same as we did for quarter) 

 

Regards

Sanghamitra

 

Hi Cherry,

 

The below graphs looks absolutely fine for me.

 

I tried this way, the problem here is i am n ot using any DB, i am using Excel. Is there a way we can write measures for excel too.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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