Forum Discussion
Power BI DAX
- 4 years ago
Hi Learner_SG ,
I got it. Here's my solution.
1.Create a check measure.
Check = IF(MAX('Sheet4'[Parsed_Date])=TODAY()-7,1)Put the measure in the visual filter and let the value is 1.
2. Create a rank measure.
Rank = RANKX ( FILTER ( ALL ( 'Sheet4' ), 'Sheet4'[Parsed_Date] = TODAY () - 7 ), CALCULATE ( SUM ( 'Sheet4'[WC Water Consumption(mL)] ) ), , DESC, DENSE )Put the measure in the visual filter and let the value <=4, get the correct result.
I attach my sample below for reference.
Best Regards,
Community Support Team _ kalyjIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Learner_SG ,
I've tried below one. But we need to change data type of WC Water Consumption to number. Can you change data type and share with me if it doesn't work, please?
rank =
- coskuersanli4 years agoResolver III
- Learner_SG4 years agoHelper IV
Thanks coskuersanli , when I try to display the measure, it shows only rank1 for every row.Is it that I am getting wrong any where?
Because , I need to select the highest 4 (hours) of previous 7th day to display it as today's cleaning time.
- coskuersanli4 years agoResolver III
We are using extr_date in measure, if we change it to parsed date it may work. Can you send me updated sample file if it doesn't work please?