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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
LachlanO
Regular Visitor

Calculate same period last year from timeframe slicer

Hi all,

 

I have one master graph which the data is populated based on the selected slicers.

 

I am trying to calculate actual enquiries recieved as well as for the same period last year (which this timeframe is specified via the Timeframe slicer). Ideally would like a measure which is dynamic so that the same period last year is calculated based on the filtered Timeframe selections.

Thanks.

 

LachlanO_1-1700442013676.png

 

1 ACCEPTED SOLUTION
LachlanO
Regular Visitor

Believe I have solved it:
=
VAR TimeframeSlicer = SELECTEDVALUE('Date Parameter (table)'[Parameter])
Return CALCULATE([Enquiries], SAMEPERIODLASTYEAR(table[EnquiryDate].[Date]))

View solution in original post

2 REPLIES 2
LachlanO
Regular Visitor

Believe I have solved it:
=
VAR TimeframeSlicer = SELECTEDVALUE('Date Parameter (table)'[Parameter])
Return CALCULATE([Enquiries], SAMEPERIODLASTYEAR(table[EnquiryDate].[Date]))
Anonymous
Not applicable

Hi @LachlanO ,

It's glad to hear that your problem has been resolved. And thanks for sharing your solution here. Could you please mark your post as Answered? It will help the others in the community find the solution easily if they face the same problem as yours.  Thank you.

Best Regards

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

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
Top Kudoed Authors