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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
learner03
Post Partisan
Post Partisan

Matrix Visual and visualization

I have a table called ProdInvc which has columns as product name, origin state, destination state, Quantity and amount. and another table which is just State that has State name. I need to make a matrix visual where in first column it is product name and then it should show Qty of each product based on origin and destination state (going across column)

 

Input

ProdInvc    
     
P.Name

O

Origin State

Destination StateQtyAmount
Ax1z120200
by1w11001000
cz1x110002000
ew1y13002000
fx1z12003000
gy1w143200
hz1x12001000
iw1y14004000
jx1z14005000
ky1z13002000
lz1w12003000
mw1x11001000
Ay1y110001000
bz1z13002000
cw1w12002000
ex1x1433000
fy1y11000200
gy1z13001000
hz1w12004000
iw1x1431000
jx1y12002000
ky1z1432000
ly1w12003000
mz1x1400200
cw1y14001000
ex1z13004000
fy1w12002000

 

State
x1
y1
z1
w1
 

 

 

Output

 

akapoor03_0-1705036720538.png

 

If there is any other visual that satisfy the above criteria, I am open to suggestions.

 

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @learner03 
To get the desired result you should unpivot the states columns with Power query.

Ritaf1983_0-1705042098539.png

Then you can create a matrix like this:

Ritaf1983_1-1705042334068.png

Pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

2 REPLIES 2
Ritaf1983
Super User
Super User

Hi @learner03 
To get the desired result you should unpivot the states columns with Power query.

Ritaf1983_0-1705042098539.png

Then you can create a matrix like this:

Ritaf1983_1-1705042334068.png

Pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

@Ritaf1983 Thanks. How can I do conditional highlight based on each row by product in this situation like, if Max quantity in the row in destination belongs to same state and max quantity belong to state in origin then do not highlight otherwise highlight both max in both (destintion & origin)

example-  max of product A is 1000 which belongs to y1 and max in origin is 1000which belongs to y1 so no highlight. Same for product B.

But for product C, Max in the destination is 1000 which belongs to x1 and max in origin is 1000 that belongs to Z1, so highlight both values here. 

In G, Max in destination  belongs to z1 which is 300 and max in origin belongs to y1 which is 343, so highlight both.

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.