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
PowerWhy
Helper IV
Helper IV

Adjusting cross filtering between visualisations

Hi,

 

I have a slicer that shows financial year 2020/2021/2022

 

This cross-filters a graph that shows the actuals and forecast for selected financial year.

 

Is it possible to adjust the cross-filter so that the graph shows rolling 12 months (not fiscal year-to-date)? (so for the current year is shows some months for the prior year). Also, for future years (that have no actuals data) is it possible to show the whole year (i.e. just the forecast?)

 

(the graph past years should just be 12 months of the respecive year)

 

Many thanks for your help,

 

CW

2 REPLIES 2
amitchandak
Super User
Super User

@PowerWhy , if the duration in selection is more than 12 month

 

This can give 12 month of trend

 

Rolling 12 Sales =
var _max = maxx(allselected(date),date[date]) // or today()
var _min = date(year(_max), month(_max)-12,1)
return
CALCULATE(SUM(Sales[Sales Amount]),filter(date, date[date] <=_max && date[date] >=_min))

 

 

and this rolling 12

 

Rolling 12 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-12,MONTH))

 

 

But if the selection is less than 12 months you can only get rolling 12 months data using

Rolling 12 = CALCULATE(sum(Sales[Sales Amount]),DATESINPERIOD('Date'[Date],MAX('Date'[Date]),-12,MONTH))

 

But you will not be able to see the trend of 12 months, for that, you need an independent table for the slicer

 


//Date1 is independent Date table, Date is joined with Table
new measure =
var _max = maxx(allselected(Date1),Date1[Date])
var _min = eomonth(_max, -12) +1
return
calculate( sum(Table[Value]), filter('Date', 'Date'[Date] >=_min && 'Date'[Date] <=_max))

 

Need of an Independent Date Table:https://www.youtube.com/watch?v=44fGGmg9fHI

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

Thanks @amitchandak but the graph should show each monthly position (for 12 months), rather than a 12 month average. Does that make sense? Thanks

Helpful resources

Announcements
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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 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.

Top Solution Authors