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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Alexbienvenue
Frequent Visitor

Confused as to why PREVIOUS MONTH not working

Hello All!

 

Not sure why my previous month measure isnt working. Ive seen this exact solution on numerous posts on here so not sure whats wrong
Previous Month Inventory.PNG

 

Any Ideas?

 

Also, would love advice on my goal for this: Assuming i figure out whats wrong could I then put this DAX into a new column in power query that would subtract the previous month from previous month etc etc...that way i could figure out the sales count amount based on subtracting current inventory from previous inventory and do some TOPN measures, thats ultimately what im after 

1 ACCEPTED SOLUTION
OwenAuger
Super User
Super User

Hello @Alexbienvenue !

First question: is there a relationship between 'Bottle Inventory'[Date] and 'Date Table'[Date]?

 

Since the measures are returning identical values, it appears that filters on 'Date Table' have no effect on 'Bottle Inventory'.

 

Also, PREVIOUSMONTH shifts dates to the calendar month preceding the earliest visible date in the filter context where the measure is evaluated. Assuming the relationship is set up correctly, Previous Month Inventory would return a blank result if no date filters are applied (since no dates in 'Date Table' precede the earliest date in 'Date Table').  You should filter on a date range for which the previous month has data to see a meaningful result. For example, include a column from 'Date Table' in the visual, or otherwise filter on 'Date Table'.

 

regards

Owen

 


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

View solution in original post

2 REPLIES 2
OwenAuger
Super User
Super User

Hello @Alexbienvenue !

First question: is there a relationship between 'Bottle Inventory'[Date] and 'Date Table'[Date]?

 

Since the measures are returning identical values, it appears that filters on 'Date Table' have no effect on 'Bottle Inventory'.

 

Also, PREVIOUSMONTH shifts dates to the calendar month preceding the earliest visible date in the filter context where the measure is evaluated. Assuming the relationship is set up correctly, Previous Month Inventory would return a blank result if no date filters are applied (since no dates in 'Date Table' precede the earliest date in 'Date Table').  You should filter on a date range for which the previous month has data to see a meaningful result. For example, include a column from 'Date Table' in the visual, or otherwise filter on 'Date Table'.

 

regards

Owen

 


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

Thank you! This worked and results are working correctly 🤝

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.