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
Anonymous
Not applicable

YTD interaction and options

I have a dataset made up of the following (minimised for ease of example):

 

Fact:

SnapshotDate

DateKey

Value

Criteria

 

Dim:

DateKey

Date

Month

 

Relationship between Fact and Dim is on DateKey and both way.

 

I've created a measure, which is:

Plan = calculate (sum ('Fact tbl'[Value]), 'Fact tbl'[Criteria] = "Plan")

I then also wish to calculate a YTD of this Plan measure, but only up to the currently selected SnapshotDate.

 

YTD Plan = calculate ([Plan], filter (all ('Dim tbl'[Date], 'Dim tbl'[Date] <= max ('Dim tbl'[Date])))

 

This works, however I can't get it to only be up to the SnapshotDate that's selected. I've tried adding allselected, selectedvalue, but it always seems to mess up.

 

Any advice appreciated!

0 REPLIES 0

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!

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.