Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
harsha449
Frequent Visitor

Data for last day of the week is not displaying until I select slicer

HI,

 

DAX is working fine, but i see data only for last monday. if i select slicer for other weekdays then only i can see the data.

 

I'm trying to see data form last day of the week. please help

 

Last Monday data is visible. I have used same dax for other days, but i can not see from Tuesday to Sunday.

Last Monday =

CALCULATE(

              sum(Company[Visits]),

              LASTDATE(Company[Date]),

              KEEPFILTERS('Company'[Day of Week Name] = "Monday")

             )

 

harsha449_6-1646157805654.png

 

However, When I select Tuesday in the slicer, I can see “Last Tuesday” data in the tables

 

Last Tuesday =

CALCULATE(

              sum(Company[Visits]),

              LASTDATE(Company[Date]),

              KEEPFILTERS('Company'[Day of Week Name] = "Tuesday")

             )

 

harsha449_7-1646157854200.png

 

I’m seeing data when the slicer is selected. Any help will be greatly appreciated.

 

Thanks,

Sri

1 ACCEPTED SOLUTION

Hi, @harsha449 , 
Thank you very much for your sample data, it was really helpful:
Please change your Last "Day" measures accordingly:

Last Friday = 

var lastFriday = MAXX(FILTER(Sheet1, Sheet1[Day of Week Name] = "Friday"),Sheet1[Date])
var __calculation  =  CALCULATE(SUM(Sheet1[Visits]),Sheet1[Date]=lastFriday)

return __calculation

View solution in original post

5 REPLIES 5
harsha449
Frequent Visitor

Shared files through google drive. Any help will be greatly appreciated.

 

https://drive.google.com/drive/folders/1GY2-3uoNOFP2KX5npS48s2qTle1otU-z?usp=sharing

Hi, @harsha449 , 
Thank you very much for your sample data, it was really helpful:
Please change your Last "Day" measures accordingly:

Last Friday = 

var lastFriday = MAXX(FILTER(Sheet1, Sheet1[Day of Week Name] = "Friday"),Sheet1[Date])
var __calculation  =  CALCULATE(SUM(Sheet1[Visits]),Sheet1[Date]=lastFriday)

return __calculation

Thanks, It is working.

Thanks for the quick response, i will test and update you.

vojtechsima
Super User
Super User

Hi, 
@harsha449 
I believe you can try adding ALL in the filter argument to ignore every filter that could be applied.
However, if you want me to have a closer look, please share sample data (in copyable form) and I can try to find a tailor-made solution.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.