Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi Experts,
I need help for getting the previous month cost if the month is not matching.
Example
Input File | ||
Items | Month | Cost |
ABC | 5/1/2018 | 1304.511 |
ABC | 6/1/2018 | 1318.111 |
ABC | 8/1/2018 | 1315.021 |
ABC | 9/1/2018 | 1315.211 |
ABC | 10/1/2018 | 1313.211 |
ABC | 11/1/2018 | 1324.321 |
ABC | 2/1/2019 | 1293.721 |
ABC | 3/1/2019 | 1293.521 |
ABC | 4/1/2019 | 1277.851 |
Output | |||
Items | Month | Cost | RS Expected result |
ABC | 1/1/2019 | 1324.321 | |
ABC | 7/1/2018 | 1318.111 |
The question here since I don't have Jan - 2019 and July -2019 sales, it should find what is the latest previous month is available based on that it should give me the result
For:- Jan-19 it's should take from Nov - 18
Jul-18 it's should take from Jun - 18
Let me know if am not very clear
Thanks
Putta
Experts, someone take a look and advise how to achieve the result.
This is an excel sheet data, I am loading to power BI, I need to know the sales if not available for the current month it should update the previous month