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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
Anonymous
Not applicable

Filter/DAX Help

Hello,

 

I have a DAX that calculates all the inventory by the end of the month, but the way the DAX is set up prevents me from using a slicer. So i changed the DAX below from ALL to AllSELECT so that I can use the slicer, but then prior month inventory dax no longer pull correctly (Prior Month inventory = Calculate (End of the month inventory], PreviousMonth(Date'Date)).

 

Is there a way I can fix my below DAX or edited the previousmonth DAX, so that I can use my slicer and both the DAX will pull correctly? Thank you!

 

End of the month Inventory =
Var thisdate =
MIN(Query1[DT_Rec_EndMonth])
return
CALCULATE(SUM(Query1[Value]),ALL(Query1),Query1[DT_Rec_EndMonth]<=thisdate,
OR(Query1[Frozen_EndMonth]>thisdate,ISBLANK(Query1[Frozen_EndMonth])))
 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Sorry I figured it out. I was being dumb. Thank you @lbendlin. Not sure how to delete this post though

View solution in original post

2 REPLIES 2
lbendlin
Super User
Super User

you want to observe the slicer but only if it's the current month?  Please provide more details.

Anonymous
Not applicable

Sorry I figured it out. I was being dumb. Thank you @lbendlin. Not sure how to delete this post though

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

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.