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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
netanel
Post Prodigy
Post Prodigy

Diff % and money

Hello everyone!
I'm trying to make a simple difference formula
But the numbers are not correct for me ...
This is the formula

Net USD LM % difference from Net USD average per Day =
VAR __BASELINE_VALUE = [Net USD average per Day]
VAR __VALUE_TO_COMPARE = [Net USD average per Day LM]
RETURN
    IF(
        NOT ISBLANK(__VALUE_TO_COMPARE),
        DIVIDE(__VALUE_TO_COMPARE - __BASELINE_VALUE, __BASELINE_VALUE)
    )
Also attach a photo
 
Thanks all!
 
 
measure.JPG







Did I answer your question?
Mark my post as a solution!
Appreciate your Kudos!

Connect on Linkedin
linkedin.com/in/netanel-shriki
1 ACCEPTED SOLUTION
VahidDM
Super User
Super User

Hi @netanel 

 

Try this:

Net USD LM % difference from Net USD average per Day =
VAR __BASELINE_VALUE = [Net USD average per Day]
VAR __VALUE_TO_COMPARE = [Net USD average per Day LM]
Var _Variance = if(ISBLANK(__VALUE_TO_COMPARE),0,__VALUE_TO_COMPARE - __BASELINE_VALUE)
RETURN
 DIVIDE(_Variance, __BASELINE_VALUE)
    

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!!

View solution in original post

3 REPLIES 3
VahidDM
Super User
Super User

Hi @netanel 

 

Try this:

Net USD LM % difference from Net USD average per Day =
VAR __BASELINE_VALUE = [Net USD average per Day]
VAR __VALUE_TO_COMPARE = [Net USD average per Day LM]
Var _Variance = if(ISBLANK(__VALUE_TO_COMPARE),0,__VALUE_TO_COMPARE - __BASELINE_VALUE)
RETURN
 DIVIDE(_Variance, __BASELINE_VALUE)
    

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!!

Hi Thanks for the quick response,

something else if I want to get the result in dollars and not in percentages? I have tried this formula but it does not work for me.

Diff $ = CALCULATE(SUMX('Revenues DB','Revenues DB'[Net USD average per Day]-'Revenues DB'[Net USD average per Day LM]))







Did I answer your question?
Mark my post as a solution!
Appreciate your Kudos!

Connect on Linkedin
linkedin.com/in/netanel-shriki

@netanel 

 

Try to use FORMAT DAX in your measure.

https://docs.microsoft.com/en-us/dax/format-function-dax

Appreciate your Kudos!!

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.