Forum Discussion
Brahms99
9 months agoFrequent Visitor
Formula to count values in two separate columns
Hello,
I am new to power bi. I am looking for a formula that would return the count of “Yes” in columns “Timesheet Submitted 1” and “Timesheet Submitted 2” combined. So, the result would would be 6.
Ideally, if I could use a formula without having to pivot the table.
ID | Timesheet Submitted 1 | Timesheet Submitted 2 |
1 | Yes |
|
2 | Yes | Yes |
3 |
| Yes |
4 | Yes | Yes |
Thank you
Hi,
If it is to work in any evaluation context, try this Measure.
Count = SUMX( 'Table', IF('Table'[Timesheet Submitted 1] = "Yes", 1, 0) + IF('Table'[Timesheet Submitted 2] = "Yes", 1, 0) )
1 Reply
- MasonMASuper User
Hi,
If it is to work in any evaluation context, try this Measure.
Count = SUMX( 'Table', IF('Table'[Timesheet Submitted 1] = "Yes", 1, 0) + IF('Table'[Timesheet Submitted 2] = "Yes", 1, 0) )