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 everyone!
I am in a situation where I have a table with 3 columns: Asset name, Month, Depreciation.
I am using PREVIOUSMONTH to find the depreciation for an asset 1 month ago.
However, if an asset is not having any depreciation in current month, then there simply is not a row for current month. In that situation, the PREVIOUSMONTH returns 0 and not the actual previous month value.
For example, how do I use the previous month formula here, so that it returns 150 (not 0) for asset 10001 and 200 for 20002?
Asset | Month | Depreciation |
10001 | 03-2021 | 150 |
20002 | 04-2021 | 100 |
20002 | 03-2021 | 200 |
Thanks!
Solved! Go to Solution.
Before you start doing any time-intel calculations, I'd strongly and kindly advise you familiarize yourself with how such things work. You can start with this: Time Intelligence in Power BI Desktop - SQLBI
Quick Hint: You are not using the time-intel function with a real date table so the result will be wrong, even if SOMETIMES it will be correct.
Before you start doing any time-intel calculations, I'd strongly and kindly advise you familiarize yourself with how such things work. You can start with this: Time Intelligence in Power BI Desktop - SQLBI
Quick Hint: You are not using the time-intel function with a real date table so the result will be wrong, even if SOMETIMES it will be correct.
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 |
---|---|
47 | |
24 | |
20 | |
15 | |
13 |
User | Count |
---|---|
55 | |
48 | |
43 | |
19 | |
19 |