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 have a dataset containing customer information like ID Nu and etc ...
I created my check in every column for example on ID Nu and I make another column called ID Nu Valid and the result was valid or not valid and the same for all other columns
what I need now is to create a table like that
CDE | Valid | Not Valid |
Customer Full Name | 92% | 8% |
Address | 98% | 2% |
Industry Code | 80% | 20% |
Please, how can I do that?
Solved! Go to Solution.
Hi , @moh3azzam
According to your description, you want to calculate the percentage of the column.
Here are the steps you can refer to :
(1)This is my test data:
(2)We can click "New Table" to create a table :
Table 2 = UNION(UNION( ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid1]) , "ColumnName","Cutomer Full Name"),
ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid2]) , "ColumnName","Address")),
ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid3]) , "ColumnName","Industry Code"))
(3)Then we can create two measures :
Valid = DIVIDE( CALCULATE( COUNT('Table 2'[validColumn]), 'Table 2'[validColumn] = "valid") , COUNT('Table 2'[validColumn]))
Not Valid = DIVIDE( CALCULATE( COUNT('Table 2'[validColumn]), 'Table 2'[validColumn] = "not valid") , COUNT('Table 2'[validColumn]))
Then we can put the fields we need on the visual and we can meet your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @moh3azzam
According to your description, you want to calculate the percentage of the column.
Here are the steps you can refer to :
(1)This is my test data:
(2)We can click "New Table" to create a table :
Table 2 = UNION(UNION( ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid1]) , "ColumnName","Cutomer Full Name"),
ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid2]) , "ColumnName","Address")),
ADDCOLUMNS( SELECTCOLUMNS('Table',"validColumn",[Valid3]) , "ColumnName","Industry Code"))
(3)Then we can create two measures :
Valid = DIVIDE( CALCULATE( COUNT('Table 2'[validColumn]), 'Table 2'[validColumn] = "valid") , COUNT('Table 2'[validColumn]))
Not Valid = DIVIDE( CALCULATE( COUNT('Table 2'[validColumn]), 'Table 2'[validColumn] = "not valid") , COUNT('Table 2'[validColumn]))
Then we can put the fields we need on the visual and we can meet your need:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
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 |
---|---|
117 | |
104 | |
77 | |
73 | |
52 |
User | Count |
---|---|
145 | |
109 | |
109 | |
90 | |
64 |