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
ngomes
Helper II
Helper II

PREVIOUSMONTH negative values

Good morning, I need your help with a dax formula

 

I have a dax measure that calculates the difference between the predicted value and the realized value

and I would like to add the negative values from the previous month to add to the predicted value of the month

 

Can anyone help me with this formula?

1 ACCEPTED SOLUTION

Hi @ngomes 

Check v2 and part YTD.

 

some_bih_0-1707407693768.png

 





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

Proud to be a Super User!






View solution in original post

7 REPLIES 7
some_bih
Super User
Super User

Hi @ngomes in your model, all inputs are on monthly level, both Excpected and billing?

It seems you need to calculate per customer and per month TOTAL Year to date difference, and also per month monthly?





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

Proud to be a Super User!






in your model, all inputs are on monthly level, both Excpected and billing?

 

R: Yes, I have the calendar table linked with sales and expected values

 

It seems you need to calculate per customer and per month TOTAL Year to date difference, and also per month monthly?

R: I need to calculate the negative value from the current year and the previous month so that later I can add it to the expected value of the current month

Hi @ngomes to provide some possible solution, please share your model with inputs and expected outputs.

On link there is idea how to use power bi to deal with budget





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

Proud to be a Super User!






I created a model identical to the one I'm using

 

send the download link SomaNegativos.pbix

Hi @ngomes 

Check v2 and part YTD.

 

some_bih_0-1707407693768.png

 





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

Proud to be a Super User!






some_bih
Super User
Super User

Hi @ngomes more details needed about measures and model to provide possible solutions. On adding negative value/s is it according rule/s or fixed amount...





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

Proud to be a Super User!






exxemplo.png

 

Knowing that in January customer A had a realized value of -€536,588.56, I want to add this value to the expected value for the month of February.

the monthly objective would be €2,181,818.18 + €536,588.56

 

thanks for any help you can give me

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.