Forum Discussion
LASTNONBLANKVALUE challenging problem
Hi, Arnault_
Thank you very much for your feedback, and I could understand much better.
If it is OK with you, please try the below.
Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster.
Hi Jihwan_Kim ,
Thank you again for your time and efforts.
We are getting close to the requirements. I am just thinking that maybe DAX is not the best approach to obtain what I am looking for. Maybe some pre-build in SQL would be better. Anyway, here is the remaining issue: the total on the right is not working properly. The first table corresponds to my measure, the 2nd to yours.
You can see two examples highlithed. On the 12th of May, the total shows 320 650 which corresponds to the 1st item only. In your measure the last non blank value is populated for the 2nd item but it is not taken into account in the sum (in the total on the right).
For the next row, on the 13th of May, it works because there are transactions on that day and as you can see it with my measure (first table), the sumx works perfectly.
From a business perspective, if I want to know the quantity in stock for these 2 items (in total) at the end of the 12th of May, your measure would tell me 320 650, instead of (320 650 + 432 400). Voilà.