I was looking for a way to create a calculated column that auto calculate the duration between dates in a date column called orderdate, with a filter of another column let’s call it Product.
I composed the following expression:
When using this expression on adventureworks data I got the results as shown in the following image
In the small red circle there are two consecutive values of 1. My goal is to subtract the dates in the red column
so because the relevant dates are identical the yellow highlited value should be zero.
How to fix the DAX expression or rewrite it to meet my goals?
Than you all