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,
I'm having troubles creating the function I mentioned in the topic.
1. I created a new table, Date_Previous = 'Date', so I got a copy of my original Date.
2. I chose Model View, and I created a 1-to-1 inactive relationship between Date(Date) and Date_Previous(Date) - Cross Filter direction: Both, otherwise it won't let me create it:
3. I created a new measure for Total Sales, previous period:
I tried to replace REMOVEFILTERS('Date'[Year]) with REMOVEFILTERS('Date'[Date]), but I didn't quite get the desired result as well:
Not sure you need the additional table. You could just use
Sales prev year =
CALCULATE ( [Total sales], PREVIOUSYEAR ( 'Date'[Date] ) )
Unfortunately, it is specifically requested to use the USERELATIONSHIP and the REMOVEFILTERS functions, that's why I'm trying to make this work this way.
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 |
---|---|
42 | |
23 | |
21 | |
15 | |
15 |
User | Count |
---|---|
45 | |
31 | |
30 | |
18 | |
17 |