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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount 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
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.