Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hello,
I'm a relatively new PBI user for context. I'm trying to ultimately create a measure that is equal to 1 for "include" and 0 for "exclude" that I can add as a filter to my page so that only certain rows are included in my visuals.
The criteria for "include" are as follows:
a row should be "included" if...
Stts Cde is closed, and Dev Period <= some parameter that the user defines (2 conditions)
OR
Stts Cde is open, and Dev Period = some parameter that the user defines (2 conditions)
I was trying a calculated column, but I'm realizing that this does not work with the parameter. However, I cannot use a measure either because I need it evaluated by row. Does anyone have any tips?
This is the DAX for the calculated column that I have so far:
Solved! Go to Solution.
Hi @Anonymous
You can transform it to measure
Calc_Filter =
VAR a =
COUNTROWS (
FILTER (
Loss_Monitoring_Tool_Full_Data,
OR (
[Stts Cde] = "closed"
&& Loss_Monitoring_Tool_Full_Data[Dev Period] <= [PARAMETER],
Loss_Monitoring_Tool_Full_Data[Stts Cde] = "open"
&& Loss_Monitoring_Tool_Full_Data[Dev Period] = [PARAMETER]
)
)
)
RETURN
IF ( a > 0, 1, 0 )
Then put the measure to the visual filter.
Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
You can transform it to measure
Calc_Filter =
VAR a =
COUNTROWS (
FILTER (
Loss_Monitoring_Tool_Full_Data,
OR (
[Stts Cde] = "closed"
&& Loss_Monitoring_Tool_Full_Data[Dev Period] <= [PARAMETER],
Loss_Monitoring_Tool_Full_Data[Stts Cde] = "open"
&& Loss_Monitoring_Tool_Full_Data[Dev Period] = [PARAMETER]
)
)
)
RETURN
IF ( a > 0, 1, 0 )
Then put the measure to the visual filter.
Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thank you that worked!
Stts Cde is a column that is either "open" or "closed"
Dev Period is an integer column with values 0 through 65
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.