This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
Good afternoon,
I am fairly new to PowerBI and I have a slight issue with creating a dax measure, which takes the price of a product in the beginning of the period as 100 (Base) and then based on the movements of the price over time gives me the percentage increase/decrease in price.
Below is a simplification of the data to ilustrate the issue.
Could someone please help me out with the creation of the measure?
Thank you very much in advance!
Kind regards,
B
Solved! Go to Solution.
Hi @ase
Please refer to thr sample file with the solution https://www.dropbox.com/t/YtiyMYOrhy8EdsCp
Your method of calculating the percentage does not seem to be consistant. Please advise if I am missing somthing
Increse/Decrese =
VAR ProductTable = CALCULATETABLE ( Prices, ALLEXCEPT ( Prices, Prices[Product] ) )
VAR BaseDate = MINX ( ProductTable, Prices[Date] )
VAR CurrentDate = MAX ( Prices[Date] )
VAR BasePrice = MAXX ( FILTER ( ProductTable, Prices[Date] = BaseDate ), Prices[Price] )
VAR CurrentPrice = MAX ( Prices[Price] )
VAR DiffirencePercent = FORMAT ( DIVIDE ( ABS ( CurrentPrice - BasePrice ), BasePrice ), "Percent" )
RETURN
IF (
CurrentDate = BaseDate,
"Base Price",
IF (
CurrentPrice >= BasePrice,
DiffirencePercent & " Increase",
DiffirencePercent & " Decrease"
)
)Thank you very much!
Hi @ase
Please refer to thr sample file with the solution https://www.dropbox.com/t/YtiyMYOrhy8EdsCp
Your method of calculating the percentage does not seem to be consistant. Please advise if I am missing somthing
Increse/Decrese =
VAR ProductTable = CALCULATETABLE ( Prices, ALLEXCEPT ( Prices, Prices[Product] ) )
VAR BaseDate = MINX ( ProductTable, Prices[Date] )
VAR CurrentDate = MAX ( Prices[Date] )
VAR BasePrice = MAXX ( FILTER ( ProductTable, Prices[Date] = BaseDate ), Prices[Price] )
VAR CurrentPrice = MAX ( Prices[Price] )
VAR DiffirencePercent = FORMAT ( DIVIDE ( ABS ( CurrentPrice - BasePrice ), BasePrice ), "Percent" )
RETURN
IF (
CurrentDate = BaseDate,
"Base Price",
IF (
CurrentPrice >= BasePrice,
DiffirencePercent & " Increase",
DiffirencePercent & " Decrease"
)
)Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 4 | |
| 4 | |
| 3 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 9 | |
| 9 | |
| 7 | |
| 6 | |
| 6 |