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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
nsaray
Helper II
Helper II

Filter on Latest Month and display Month and Year

Hi

I have 3  visuals on a page, 2 has trend informaton  so the date filters range over a few months. The last visual I only want to display data from the latest month of the available dataset.

1. How can I filter the one visual to only show the latest month's worth of data. ie. If it's currently Oct 2021, but in my dataset the last month of data  I have is May 2021, I want it to display May 2021 data.

2. How do I then also display it as Mon YYYY on a card visual (ie. May 2021)

 

Thanks!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@nsaray , You need use the first column in date table and select last month in slicer

 


Month Type = Switch( True(),
eomonth([Date],0)= eomonth(maxx((Table), Table[Date]),0), "Last Month" ,
Format([Date],"MMM-YYYY")
)

 

You can use this measure to displat last month

last month = format(maxx(allselected(Table), Table[Date]), "MMMM-YYYY")

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@nsaray , You need use the first column in date table and select last month in slicer

 


Month Type = Switch( True(),
eomonth([Date],0)= eomonth(maxx((Table), Table[Date]),0), "Last Month" ,
Format([Date],"MMM-YYYY")
)

 

You can use this measure to displat last month

last month = format(maxx(allselected(Table), Table[Date]), "MMMM-YYYY")

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Perfect, thank you!!

Helpful resources

Announcements
Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.