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
Anonymous
Not applicable

Quarter over Quarter - Data Comparison

Hello! Thank you so much in advance for your time on this post.

 

I have a chart that shows the count of engaged users over time. I wanted to do a PoP (Period over Period) comparison. To facilitate this, I created a measure that would essentially duplicate the user count and push it into the future by 1 quarter (or) 3 monhts.

 

** Removing the actual DB names because of confidentiality 

measure= CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH))

 

Now, when I inspect the data of my Viz, I have this:

 

Year, Qtr         Count of users                   measure                          Earliest Date

2017,q2             1000                                                                           4/1/2017

2017,q3             1500                                  1000                                 7/1/2017

2017,q4             1100                                  1500                               10/1/2017

2018, q1            2000                                  1100                                 1/1/2018

2018, q2            2200                                  2000                                 4/1/2018

2018, q3                                                      2200                                 7/1/2018

 

Since we don't have count of users for 2018 q3 (q3 hasn't started yet) I don't want that last portion to appear in my chart.

Right now, I am doing a "dirty fix". I'm checking if the count of users is greater than 0 as a visual level filter.

Is there a better way of doing this?

 

P.S, I tried attaching images and for some reason, chrome won't work 😐 

 

Thanks again 🙂

 

Best,

Bharath

 

 

 

1 ACCEPTED SOLUTION
v-juanli-msft
Community Support
Community Support

Hi
 
Add a condition to the measure, if the “Count of users” is a measure,
measure= IF([Count of users]>0, CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH)),BLANK())
 
If the “Count of users” is a column,
measure= IF(MAX ([Count of users])>0, CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH)),BLANK())
 
Or
Create a calculated column instead of a measure with the following formula.
column= CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH))
But a calculated column can’t change with any slicer.
 
 
Best Regards
Maggie

View solution in original post

2 REPLIES 2
v-juanli-msft
Community Support
Community Support

Hi
 
Add a condition to the measure, if the “Count of users” is a measure,
measure= IF([Count of users]>0, CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH)),BLANK())
 
If the “Count of users” is a column,
measure= IF(MAX ([Count of users])>0, CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH)),BLANK())
 
Or
Create a calculated column instead of a measure with the following formula.
column= CALCULATE(DISTINCTCOUNT(users), PARALLELPERIOD(Date,-3,MONTH))
But a calculated column can’t change with any slicer.
 
 
Best Regards
Maggie
Anonymous
Not applicable

Thanks a lot for your help 🙂

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.