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.
Hi Guys,
I have 42 weeks with data in the matrix table. When choosing from the filter (2 weeks), I would like to be able to subtract the values from each other. But I would like to be able to subtract values from different weeks (depending on which I choose from the filter) - e.g. week 4 - week 5. But it could also be week 40 - week 32.
How can I make such a column at the end?
The problem is also that I can't add any new columns to the model, I have to rely on measures.
Please find the screen below.
Solved! Go to Solution.
@Arti12 , A measure like
sales =
var _max = maxx(allselected('Date'),'Date'[Week])
var _min = minx(allselected('Date'),'Date'[Week])
return
calculate([Measure], filter('Date', 'Date'[Week] =_max)) - calculate([Measure], filter('Date', 'Date'[Week] =_min))
or
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
@Arti12 , A measure like
sales =
var _max = maxx(allselected('Date'),'Date'[Week])
var _min = minx(allselected('Date'),'Date'[Week])
return
calculate([Measure], filter('Date', 'Date'[Week] =_max)) - calculate([Measure], filter('Date', 'Date'[Week] =_min))
or
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
Dear @amitchandak,
Thanks for answer. Unfortunately I can't send the source but let me be more specific.
The problem is that I cannot insert any column in the model, only measures. I would like to have only one value in the end - the result of substraction.
Is it possible to implement?
I've tried your measure but it didn't work.
BR,
Artur
Hi @Arti12,
Can you please share a pbix or some dummy data that keep raw data structure with expected results? It should help us clarify your scenario and test to coding formula.
How to Get Your Question Answered Quickly
Regards,
Xiaoxin Sheng
Anyone? 🙂
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
105 | |
94 | |
75 | |
63 | |
62 |
User | Count |
---|---|
137 | |
105 | |
104 | |
80 | |
63 |