Forum Discussion
EnderWiggin
Helper I
4 years agoFilter Calendar lookup table based on fact table value
Hi All, I would like to ask your help to find a solution of the following case. I would like to get the minimum Calandar[Date] value which is equal or greater than TransctionPast[FirstValid] date. ...
- Anonymous4 years ago
You would not return anything if you compare Date with MIN('TransactionPast'),[FirstValid]). If you would to compare Calendar date with minimum date in [FirstValid] column.
Try:
Measure = CALCULATE(MIN('Calendar'[Date]),FILTER('Calendar',[Date]>=MINX(ALL('TransactionPast'),[FirstValid])))Best regards
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
EnderWiggin
Helper I
4 years agoAnonymous, you are right in some cases the 'TransactionPast'),[FirstValid]) value was not available becasue of the filter context, so this was the root cause of the high memory usage. Your measure works, so thank you very much for the solution and your response!