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,
Can you try below measure and use it as visual filter please?
- Learner_SG4 years agoHelper IV
Hi coskuersanli , I am still unable to get the solution. Actually , I had shared the data for another query to you.If you have time , could u guide me with the DAX.
https://drive.google.com/file/d/1rgIn7gN7Kuux8trVMtPIj8qxxulUVYLL/view?usp=sharing.
- coskuersanli4 years agoResolver III
Hi Learner_SG ,
Dates and hours are unique in sample file. I can help if you send me some data like in your first post 🙂
- Learner_SG4 years agoHelper IV
Hi coskuersanli , Because the data is captured on a real time basis the difference between the times are very close. I have attached another file with more data .
https://drive.google.com/file/d/1O8ohw7KfZ6fealUfS0iyeDd4SLnsSTBO/view?usp=sharing.
what I need to come up , is based on the WC water consumption data I need to get the highest 4 times( the hours) on each day and later I need to display it in a table. Appreciate the help.tks.