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! Request now

Reply
Anonymous
Not applicable

Calculer la différence entre deux mois

Hello,

 

I am trying to calculate the difference between the current month and the previous month.

To calculate the number of rows in my table I use the following formula:

#Deskphone & Fax = CALCULATE(COUNTROWS(UOP),FILTER(UOP,UOP[Deskphone & Fax]="Deskphone & Fax"))
It gives me a lot of value
But I can't find how to calculate and display the difference between the current month and the previous month.
I am attaching two screenshots for information.

JPCO_0-1671629416003.png

 

JPCO_1-1671629464784.png

 

 
2 ACCEPTED SOLUTIONS
Anonymous
Not applicable

Hi @Anonymous ,

 

Please try:

Difference = 
VAR _current_month = [#Deskphone & Fax]
VAR _previous_month = CALCULATE([#Deskphone & Fax],PREVIOUSMONTH('Calendar'[Date]))
VAR _result = _current_month-_previous_month
RETURN
_result

and drag the 'calendar[Year],'calendar'[month] and the measure into the table visual.

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

View solution in original post

Anonymous
Not applicable

Hello,

Congratulation it is the best solution

Thank you for your help

BR,

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hello,

Congratulation it is the best solution

Thank you for your help

BR,

Anonymous
Not applicable

Hi @Anonymous ,

 

Please try:

Difference = 
VAR _current_month = [#Deskphone & Fax]
VAR _previous_month = CALCULATE([#Deskphone & Fax],PREVIOUSMONTH('Calendar'[Date]))
VAR _result = _current_month-_previous_month
RETURN
_result

and drag the 'calendar[Year],'calendar'[month] and the measure into the table visual.

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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.