Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hello All,
I want to filter data with last 15 months of data from max date
Please help
Thanks!
Solved! Go to Solution.
@Anonymous You can create a new Custom Column in Power Query to present months difference from Max Date Month by using the following Power Query Formula
Date.Month([Date]) - Date.Month(List.Max(#"Sorted Rows"[Date])) +
(Date.Year([Date]) - Date.Year(List.Max(#"Sorted Rows"[Date]))) * 12
Then apply a Filter on new column where months difference is greater than -15, so that only last 15 months data should be availble to use.
Regards,
Fahad Qadir
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !!
@Anonymous You can create a new Custom Column in Power Query to present months difference from Max Date Month by using the following Power Query Formula
Date.Month([Date]) - Date.Month(List.Max(#"Sorted Rows"[Date])) +
(Date.Year([Date]) - Date.Year(List.Max(#"Sorted Rows"[Date]))) * 12
Then apply a Filter on new column where months difference is greater than -15, so that only last 15 months data should be availble to use.
Regards,
Fahad Qadir
Did I answer your question? Mark my post as a solution! Appreciate your Kudos !!
Are you meaning the last 15 calendar months? Or are you meaning (15months)*(~30days/month) = ~450 days?
Are you wanting this as a DAX measure or a visual-level filter or a page-level filter or a report-level filter? Are you wanting to screen out data older than 15 months at the import level using Power Query?
When you say "max date" are you referring to a date selected in a slicer, or are you referring to today's date (whatever that happens to be), or are you referring to the latest date found in a certain table?
More information about the exact problem you're trying to solve is going to help us answer your question. As much as you can provide.
///Mediocre Power BI Advice, but it's free///
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.