Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
NipponSahore
Resolver II
Resolver II

Filtering matrix only on columns, but display all rows

Hi all, 

 

I got a requirement where i have the data available in the following format 

 

Customer Item sold Item type Amount 
Customer1Item1Type 11
Customer2Item2Type 21
Customer3Item4Type 21
Customer4Item2Type 21
Customer5Item3Type 11
Customer6Item4Type 21
Customer7Item3Type 11
Customer8Item1Type 11
Customer9Item2Type 21
Customer10Item4Type 21
Customer1Item2Type 21
Customer2Item3Type 11
Customer3Item4Type 21
Customer4Item3Type 11
Customer5Item1Type 11
Customer6Item2Type 21
Customer7Item4Type 21
Customer8Item2Type 21
Customer9Item3Type 11
Customer10Item4Type 21

 

My requriement is to visualize data in a matrix and allow to slice data on Item type (Type1/Type2), However still show all the customers where sale is not made for said item type. 

 

Example output on slicing on Item Type = Type 1

 

Customer Item 1Item3
Customer11 
Customer2 1
Customer3  
Customer4 1
Customer511
Customer6  
Customer7 1
Customer81 
Customer9 1
Customer10 

 

 

Similaryly, slicing on Item Type = Type 2

Customer Item 2Item4
Customer11 
Customer21 
Customer3 1
Customer41 
Customer5  
Customer611
Customer7 1
Customer81 
Customer91 
Customer10 1

 

Please show me the light. 🙂 

1 ACCEPTED SOLUTION

Hi @NipponSahore,

 

I'm sorry for misunderstand your requirement before. Now you could follow the steps below to get your desired output.

 

1. Create a calculated table to get the all customers and create the relationship of the two tables.

 

Table = VALUES(Sheet22[Customer ])

2. Create the measure in your original table.

 

Measure = var a= COUNT(Sheet22[Amount ]) return IF(ISBLANK(a),0,1)

3. Then you could ceate the matrix with the new Customer you created in the Table as Rows and Item sold as Columns , the measure as Values.

 

You could see the difference with the picture below.

 

Capture.PNG

For reference, you could have a look at my pbix file which has been attached.

 

Hope this can help you!Smiley Wink

 

Best Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @NipponSahore,

 

Do you want to have the output below?

 

Untitled.png

If it is your requirement, you only need to create the matrix with the Customer as Row, Item sold as Column and Amount as Values.

 

If I misunderstood your case, please let me know and show your expcted output, so that we can help further investigate on it?

 

Best Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-piga-msft

 

Acutally my output should be be different. 

 

I want it to display list of all the customers not just one's who've been sold the item under that type. 

 

So, in the matrix 

 

Rows --> All Customers

Columns --> only items which lie in Item type

Value -->  1 or 0 if item is sold  or not respectively

Hi Guys,

 

Any suggestions or tips ?

Hi @NipponSahore,

 

I'm sorry for misunderstand your requirement before. Now you could follow the steps below to get your desired output.

 

1. Create a calculated table to get the all customers and create the relationship of the two tables.

 

Table = VALUES(Sheet22[Customer ])

2. Create the measure in your original table.

 

Measure = var a= COUNT(Sheet22[Amount ]) return IF(ISBLANK(a),0,1)

3. Then you could ceate the matrix with the new Customer you created in the Table as Rows and Item sold as Columns , the measure as Values.

 

You could see the difference with the picture below.

 

Capture.PNG

For reference, you could have a look at my pbix file which has been attached.

 

Hope this can help you!Smiley Wink

 

Best Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

hi @v-piga-msft

 

Thank you for the solution, 

 

However i also have another slicer which is applied. and this Solution overides all slicers not just the Type Slicer. Any Suggestions.

 

Thanks

Nippon

 

I got a requirement where i have the data available in the following format 

 

Customer Item sold Item type Amount 
Customer1Item1Type 11
Customer2Item2Type 21
Customer3Item4Type 21
Customer4Item2Type 21
Customer5Item3Type 11
Customer6Item4Type 21
Customer7Item3Type 11
Customer8Item1Type 11
Customer9Item2Type 21
Customer10Item4Type 21
Customer1Item2Type 21
Customer2Item3Type 11
Customer3Item4Type 21
Customer4Item3Type 11
Customer5Item1Type 11
Customer6Item2Type 21
Customer7Item4Type 21
Customer8Item2Type 21
Customer9Item3Type 11
Customer10Item4Type 21

 

My requriement is to visualize data in a matrix and allow to slice data on Item type (Type1/Type2), However still show all the customers where sale is not made for said item type. 

 

Example output on slicing on Item Type = Type 1

 

Customer Item 1Item3
Customer11 
Customer2 1
Customer3  
Customer4 1
Customer511
Customer6  
Customer7 1
Customer81 
Customer9 1
Customer10 

 

 

Similaryly, slicing on Item Type = Type 2

Customer Item 2Item4
Customer11 
Customer21 
Customer3 1
Customer41 
Customer5  
Customer611
Customer7 1
Customer81 
Customer91 
Customer10 1

 

Please show me the light. Smiley Happy 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.