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

Measure not being filtered in by connected table

Good morning everyone,

 

I hope everyone is staying healthy and safe during these times.

 

I have a problem that I've been working on for a few days and can't seem to figure out. A few months ago I posted here about having a value extend forwards but not backwards. (Link here)

 

It worked amazingly! However, recently I cleaned up a table that is connected to the table this measure references. now it no longer filters the formula below.  I confirmed the model connections are right by doing a join.

 

Here is the code:

Predicted Budget =
VAR _curval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
FILTER(
'Predictive Financial Data',
'Predictive Financial Data'[Accuracy Date] = MAX('Calendar Table'[Date])
)
)

VAR _maxdate =
CALCULATE(MAX('Predictive Financial Data'[Accuracy Date]), ALL('Predictive Financial Data'))

VAR _foreval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
FILTER(ALL('Predictive Financial Data'), 'Predictive Financial Data'[Accuracy Date] = _maxdate)
)
 
RETURN
IF(MAX('Calendar Table'[Date]) <= _maxdate, _curval, _foreval)
 
Any help anyone can provide would be greatly appreciated.
 
Thanks in advance,
 
Vanlang
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Never mind, I solved it. 🙂

 

I had to alter the code to the following:

 

Predicted Budget =
VAR _curval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
FILTER(
'Predictive Financial Data',
'Predictive Financial Data'[Accuracy Date] = MAX('Predictive Financial Data'[Accuracy Date])
 
)
)

VAR _maxdate =
CALCULATE(MAX('Predictive Financial Data'[Accuracy Date]), ALL('Predictive Financial Data'))

VAR _foreval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
//FILTER(ALL('Predictive Financial Data'), 'Predictive Financial Data'[Accuracy Date] = _maxdate)
FILTER(
'Predictive Financial Data',
'Predictive Financial Data'[Accuracy Date] = MAX('Predictive Financial Data'[Accuracy Date])
))

RETURN
IF(MAX('Calendar Table'[Date]) = _maxdate, _curval,
IF(MAX('Calendar Table'[Date]) < _maxdate, BLANK(),
_foreval)
)

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Never mind, I solved it. 🙂

 

I had to alter the code to the following:

 

Predicted Budget =
VAR _curval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
FILTER(
'Predictive Financial Data',
'Predictive Financial Data'[Accuracy Date] = MAX('Predictive Financial Data'[Accuracy Date])
 
)
)

VAR _maxdate =
CALCULATE(MAX('Predictive Financial Data'[Accuracy Date]), ALL('Predictive Financial Data'))

VAR _foreval =
CALCULATE(
SUM('Predictive Financial Data'[Total Notional Budget (A = B + C)]),
//FILTER(ALL('Predictive Financial Data'), 'Predictive Financial Data'[Accuracy Date] = _maxdate)
FILTER(
'Predictive Financial Data',
'Predictive Financial Data'[Accuracy Date] = MAX('Predictive Financial Data'[Accuracy Date])
))

RETURN
IF(MAX('Calendar Table'[Date]) = _maxdate, _curval,
IF(MAX('Calendar Table'[Date]) < _maxdate, BLANK(),
_foreval)
)

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

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!

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