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

Get Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.

Reply
Anonymous
Not applicable

should not use function as part of calculate filter boolean expression?

Hi

why line 5 works well but line 6 error cause of A function 'ENDOFMONTH' has been used in a True/False expression that is used as a table filter expression. This is not allowed.

 1 Inflow_KPI2 =
2 VAR CurDate = ENDOFMONTH(Inflow_non5g[Date])
3 RETURN
4 CALCULATE( MAX(Inflow_non5g[O&M OSS&EMS]),
5      //Inflow_non5g[Date] = CurDate
6     Inflow_non5g[Date] = ENDOFMONTH(Inflow_non5g[Date])
7 )

Thanks a lot!

Smiley Tongue

2 REPLIES 2
v-yulgu-msft
Microsoft Employee
Microsoft Employee

Hi @Anonymous ,

 

You should modify the formula as below:

Inflow_KPI2 =
VAR CurDate = ENDOFMONTH(Inflow_non5g[Date])
RETURN
CALCULATE( MAX(Inflow_non5g[O&M OSS&EMS]),
Inflow_non5g[Date] = FILTER(Inflow_non5g,Inflow_non5g[Date]=ENDOFMONTH(Inflow_non5g[Date])))

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

@v-yulgu-msft  Thanks for help.

post from you should work, but i want to know why

 1 Inflow_KPI2 =
2 VAR CurDate = ENDOFMONTH(Inflow_non5g[Date])
3 RETURN
4 CALCULATE( MAX(Inflow_non5g[O&M OSS&EMS]),
5      Inflow_non5g[Date] = CurDate
6 )

works well. But

 1 Inflow_KPI2 =
2 VAR CurDate = ENDOFMONTH(Inflow_non5g[Date])
3 RETURN
4 CALCULATE( MAX(Inflow_non5g[O&M OSS&EMS]),
5     Inflow_non5g[Date] = ENDOFMONTH(Inflow_non5g[Date])
6 )

 

cannot, but error with A function 'ENDOFMONTH' has been used in a True/False expression that is used as a table filter expression. This is not allowed.

What's the difference between these two?

 

Regards

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.