Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Hi Community, I'm trying to get the value from the previous month in the following table, which is about trying to see if there was a change in the employee status (employee is "active" or "on leave"). Does anyone know how to get it? I already found some ideas in older chats but I didn't manage to make it work.
Thank you in advance!
| Month/Year | Employee ID | Status | Status PRV Month |
| 30.06.2024 | 1188 | On Leave | |
| 30.06.2024 | 1066 | On Leave | |
| 30.06.2024 | 1100 | Active | |
| 30.06.2024 | 900 | Active | |
| 30.06.2024 | 1155 | Active | |
| 30.06.2024 | 1245 | Active | |
| 30.06.2024 | 1056 | Active | |
| 31.07.2024 | 1188 | Active | On Leave |
| 31.07.2024 | 1066 | Active | On Leave |
| 31.07.2024 | 1100 | On Leave | Active |
| 31.07.2024 | 900 | Active | Active |
| 31.07.2024 | 1155 | Active | Active |
| 31.07.2024 | 1245 | Active | Active |
| 31.07.2024 | 1056 | Active | Active |
| 31.08.2024 | 1188 | Active | Active |
| 31.08.2024 | 1066 | Active | Active |
| 31.08.2024 | 1100 | On Leave | On Leave |
| 31.08.2024 | 900 | Active | Active |
| 31.08.2024 | 1155 | Active | Active |
| 31.08.2024 | 1245 | On Leave | Active |
| 31.08.2024 | 1056 | Active | Active |
I already tried this without success:
Solved! Go to Solution.
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
@Werfuks - It looks like you have not created a date table, which is essential for doing time intelligence calculations. You can build a simple one using CALENDARAUTO() when creating a calculated table. There is also a great video of options here: https://www.youtube.com/watch?v=WybnTHDl-AM
Once you have done this, make sure you create a relationship between your new date table date column and the date column in your Basisdaten_Headcount table.
You can then use the following DAX to create the measure - you will need to change names to suit your model:
CALCULATE( [Measure], DATEADD('Date Table'[Date Column],-1,MONTH)
If this works for you, pelase accept it as the solution for others - it helps with visibility.
@Werfuks - It looks like you have not created a date table, which is essential for doing time intelligence calculations. You can build a simple one using CALENDARAUTO() when creating a calculated table. There is also a great video of options here: https://www.youtube.com/watch?v=WybnTHDl-AM
Once you have done this, make sure you create a relationship between your new date table date column and the date column in your Basisdaten_Headcount table.
You can then use the following DAX to create the measure - you will need to change names to suit your model:
CALCULATE( [Measure], DATEADD('Date Table'[Date Column],-1,MONTH)
If this works for you, pelase accept it as the solution for others - it helps with visibility.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 5 | |
| 4 | |
| 3 | |
| 3 |
| User | Count |
|---|---|
| 24 | |
| 12 | |
| 11 | |
| 9 | |
| 8 |