Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hello everyone,
I am attempting to create a calculated column in the 'WFS Metrics' table with the following formula. My goal is to count the rows in the 'BAT Counts' table where the 'BAT Counts'[Full Name] field matches a name in the 'WFS Metrics'[Full Name] table/field while also making sure that the 'ACS BAT'[Condition] field equals "DCS-START" while none of the three tables have an active relationship. Any help would be appreciated, thanks.
Solved! Go to Solution.
Thanks for the replies from Laxmanjatoth and lbendlin.
Hi @rschubs ,
It is recommended that you create relationships between the three table. The RELATED function can then be used:
Column = COUNTROWS(FILTER('BAT Counts',RELATED('ACS BAT'[Condition])="DCS-START"&&'BAT Counts'[Full Name]=RELATED('WFS Metrics'[Full Name]))
)
The LOOKUPVALUE function can be used without creating a relationship, for example:
condition = LOOKUPVALUE('ACS BAT'[Condition],'ACS BAT'[Index],'BAT Counts'[Index])
Column = COUNTROWS(FILTER('BAT Counts','BAT Counts'[Full Name]=RELATED('WFS Metrics'[Full Name])&&'BAT Counts'[condition]="DCS-START"))
Best Regards,
Zhu
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks for the replies from Laxmanjatoth and lbendlin.
Hi @rschubs ,
It is recommended that you create relationships between the three table. The RELATED function can then be used:
Column = COUNTROWS(FILTER('BAT Counts',RELATED('ACS BAT'[Condition])="DCS-START"&&'BAT Counts'[Full Name]=RELATED('WFS Metrics'[Full Name]))
)
The LOOKUPVALUE function can be used without creating a relationship, for example:
condition = LOOKUPVALUE('ACS BAT'[Condition],'ACS BAT'[Index],'BAT Counts'[Index])
Column = COUNTROWS(FILTER('BAT Counts','BAT Counts'[Full Name]=RELATED('WFS Metrics'[Full Name])&&'BAT Counts'[condition]="DCS-START"))
Best Regards,
Zhu
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Matching Count =
CALCULATE(
COUNTROWS('BAT Counts'),
FILTER(
'BAT Counts',
'BAT Counts'[Full Name] = 'WFS Metrics'[Full Name] &&
'ACS BAT'[Condition] = "DCS-START"
)
)
let me know if you still help
Best,
Laxman jatoth
Please provide a more detailed explanation of what you are aiming to achieve. What have you tried and where are you stuck? How are these three tables related?
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
9 | |
8 | |
8 | |
8 |
User | Count |
---|---|
13 | |
12 | |
11 | |
10 | |
8 |