Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi all,
I need to calculate the average of value and value at the end of previous year. I can use measure for value and also value at the end of 2021 is solved. What I'm missing is end-of-year values for the year 2020.
I can't figure out why it works for 2022 (closing value of 2021) but not for 2021 (closing value of 2020).
I'm using following the calculate Prev Year Close
Picture below describers the current status. During 2021 it should show 811 (value at Dec 2020). During 2022 it shows 818 as expected.
Cheers,
Juha
Solved! Go to Solution.
@JPO_10 , You can use openingbalanceyear - https://youtu.be/6lzYOXI5wfo
it gives the last date of the last year
or
Last year last day sales = CALCULATE(lastnonblankvalue(sales[Sales Date], SUM(Sales[Sales Amount])),previousyear('Date'[Date]))
Hi @JPO_10 ,
Please check the measures in PBIX file:
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
Hi @JPO_10 ,
Please check the measures in PBIX file:
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data
@JPO_10 , You can use openingbalanceyear - https://youtu.be/6lzYOXI5wfo
it gives the last date of the last year
or
Last year last day sales = CALCULATE(lastnonblankvalue(sales[Sales Date], SUM(Sales[Sales Amount])),previousyear('Date'[Date]))
User | Count |
---|---|
103 | |
87 | |
77 | |
70 | |
69 |
User | Count |
---|---|
113 | |
99 | |
97 | |
72 | |
68 |