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
Alex_G7
Helper I
Helper I

Dynamically position column in matrix based on Total of column

Hi everybody,

 

Example of table I have 

LocationOrdersInCharge
Dublin3Store
Dublin4Client
Dublin1Factory
London4Driver
London1Office
Line1Driver
Line1Client
Line23Line
Berlin6Store
Berlin32Others
Berlin11Billing
Berlin8Driver
Berlin55Client
Berlin13Office
Berlin1Dockers
Berlin2Line
Berlin54Factory
Madrid10Store
Madrid4Others
Madrid1Billing
Madrid7Driver
Madrid202Client
Madrid6Office
Madrid1Dockers
Madrid1Line
Madrid73Factory

 

Matrix created 

Alex_G7_0-1616632415438.png

   Based on Totals of columns I need reorder   from left to right   how columns displaied in matrix.

   Column with max total on left and so on  

   it should  be 

   Client |Factoty|Others|Line|Driver| Office|Store|Billing ...

Alex_G7_1-1616632855953.png

 

Thank for any suggestions

 

 

1 ACCEPTED SOLUTION
v-deddai1-msft
Community Support
Community Support

Hi @Alex_G7 ,

 

You can try to create a new calculated table and use the [Incharge] column in it :

Summarytable = SUMMARIZE('Table','Table'[InCharge],"total",SUM('Table'[Orders]))

Capture.PNG

 

Sort the Incharge column by the total column:

 

Capture1.PNG

 

Create new measure for the values:

Measure = CALCULATE(SUM('Table'[Orders]),TREATAS(VALUES(Summarytable[InCharge]),'Table'[InCharge]))

Use the incharge from the summarytable:

 

Capture2.PNG

 

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

 

Best Regards,

Dedmon Dai

 

View solution in original post

2 REPLIES 2
v-deddai1-msft
Community Support
Community Support

Hi @Alex_G7 ,

 

You can try to create a new calculated table and use the [Incharge] column in it :

Summarytable = SUMMARIZE('Table','Table'[InCharge],"total",SUM('Table'[Orders]))

Capture.PNG

 

Sort the Incharge column by the total column:

 

Capture1.PNG

 

Create new measure for the values:

Measure = CALCULATE(SUM('Table'[Orders]),TREATAS(VALUES(Summarytable[InCharge]),'Table'[InCharge]))

Use the incharge from the summarytable:

 

Capture2.PNG

 

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

 

Best Regards,

Dedmon Dai

 

amitchandak
Super User
Super User

@Alex_G7 , I doubt there is an option for that. You check and vote or suggest a new idea https://ideas.powerbi.com/ideas/

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.