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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello,
I've got a demo data :
i.e
| SLNO | PRODUCT | TYPE |
| 1 | A | X1 |
| 1 | B | X2 |
| 1 | C | X3 |
| 1 | D | X1 |
| 1 | E | X4 |
| 1 | R | X2 |
| 1 | F | X1 |
| 1 | G | X2 |
| 1 | I | X1 |
| 2 | J | X1 |
| 2 | K | X1 |
| 2 | M | X1 |
| 2 | L | X2 |
| 2 | N | X2 |
| 2 | O | X2 |
and
my required calculated column is like
| SLNO | X1 | X2 | X3 | X4 | TOTAL |
| 1 | 4 | 3 | 1 | 1 | 9 |
| 2 | 3 | 3 | 0 | 0 | 6 |
Thanks & Regards...
Solved! Go to Solution.
Hi, @BIswajit_Das
Based on the further requirements you have provided me, it seems that you are trying to achieve the effect you need not by matrix but by calculate column.
You can create a calculated column to calculate the number of rows of type "X1" in the first column.
X1 =
COUNTROWS(FILTER('Table', 'Table'[SLNO] = 1 && 'Table'[TYPE] = "X1"))
This method is available in the final Visualizations to get the final results you need.
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello @Anonymous is it possible without using matrix
Creating a caculated column instead
Hi, @BIswajit_Das
Based on the further requirements you have provided me, it seems that you are trying to achieve the effect you need not by matrix but by calculate column.
You can create a calculated column to calculate the number of rows of type "X1" in the first column.
X1 =
COUNTROWS(FILTER('Table', 'Table'[SLNO] = 1 && 'Table'[TYPE] = "X1"))
This method is available in the final Visualizations to get the final results you need.
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @BIswajit_Das
Based on the information you have provided, Here are my answers to your questions.
1. Create a table according to your requirements.
2. Create a Matrix with SLNO as Rows and TYPE as Columns.
3. Create a Measure and migrate it to Values.
Measure =
COUNTROWS('Table (2)')
4. Then you can get the results you need
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
You can't dynamically add columns to a calculated table (ie X1/X2/X3 ...); thus use pivot table viz or transform it in PQ by unpivoting TYPE column.
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 36 | |
| 33 | |
| 30 | |
| 28 |
| User | Count |
|---|---|
| 127 | |
| 88 | |
| 78 | |
| 66 | |
| 65 |