Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi,
I am trying to calculate the number of accounts in my table that have a blank value in different columns, example:
Account | ColumnA | ColumnB | ColumnC | ColumnD | ColumnE | ColumnF |
1DC | A | UP | BLACK | X | 364 | |
32A | B | DOWN | 2 | Y | 789 | |
85B | C | 3 | WHITE | Y | ||
5JF | C | DOWN | 1 | BLACK | Y | 456 |
6IT | B | DOWN | 1 | X | 566 | |
3CB | A | 2 | WHITE | X | 921 | |
1AL | ||||||
6KT | B | UP | 3 | WHITE | X | 421 |
4JK | UP | WHITE | X | 689 | ||
7LZ | BLACK | Y | ||||
9IM | C | DOWN | 2 | X | 674 |
The result that I want is 9, because 9 accounts have blank values, I don't want to se how many blanks, 19 would be wrong.
How can I make in DAX a measure that will calculate that? I was trying with this but is not working when soing the sum
Solved! Go to Solution.
Hi @Aydeedglz ,
You can update the formula of measure [d_HighestBlank_AccountOwner] as below and check if it can achieve your requirement.
d_HighestBlank_AccountOwner =
CALCULATE (
DISTINCTCOUNT ( 'Table'[Account] ),
FILTER (
'Table',
'Table'[ColumnA] = BLANK ()
|| 'Table'[ColumnB] = BLANK ()
|| 'Table'[ColumnC] = BLANK ()
|| 'Table'[ColumnD] = BLANK ()
|| 'Table'[ColumnE] = BLANK ()
|| 'Table'[ColumnF] = BLANK ()
)
)
Best Regards
Hello @Aydeedglz ,
Please try the following DAX:
If this works please mark this as accepted solution.
Hi, I am doing the same and is not working for me, the issue I think is that my table have more columns and rows, I need to count the Account column, not the whole table. I provided an example table but is much bigger becuase I can't share the original data.
How can instead of sumx the whole table, sum only the number of "account"?
I want the distinct count of the "account" column. How many distinct accounts have a blank in column a or b or c or d or e or f.
Hi @Aydeedglz ,
You can update the formula of measure [d_HighestBlank_AccountOwner] as below and check if it can achieve your requirement.
d_HighestBlank_AccountOwner =
CALCULATE (
DISTINCTCOUNT ( 'Table'[Account] ),
FILTER (
'Table',
'Table'[ColumnA] = BLANK ()
|| 'Table'[ColumnB] = BLANK ()
|| 'Table'[ColumnC] = BLANK ()
|| 'Table'[ColumnD] = BLANK ()
|| 'Table'[ColumnE] = BLANK ()
|| 'Table'[ColumnF] = BLANK ()
)
)
Best Regards
This one worked! Really thanks for the help!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
96 | |
95 | |
82 | |
71 | |
64 |
User | Count |
---|---|
116 | |
106 | |
94 | |
79 | |
72 |