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
Anonymous
Not applicable

Classifying a pivot table

Hi, 

 

I have Sales Table and a "pivot table" in my dashboard wich I'm trying to classify it. One of the columns shows the probability of closing that sale, that can be "Very high", "High", or "Medium".

 

I'd like to classify from "Very High" to "Medium", but the Power BI only allows me to classify alphabetically. How can I make this work?

1 ACCEPTED SOLUTION

Hi, @Anonymous 

As mentioned by @selimovd ,you should create a calculated column rather than a measure, then sort column by this new calculated colum.

22.png

You can also consider creating  the following sort table  (here you also need to select the column "probability" and sort it by column "column1") . You need to use the field "probability" in this new table to create visual.

 

26.png

Please check my attached file for more details.

 

 

Best Regards,
Community Support Team _ Eason

View solution in original post

4 REPLIES 4
selimovd
Super User
Super User

Hey @Anonymous ,

 

you can create a sort by column in the table. This table should contain the order, something like this would do it:

 

SoryByColumn =
SWITCH(
    TRUE(),
    myTable[classification] = "Very high", 1,
    myTable[classification] = "High", 2,
    myTable[classification] = "Medium", 3
)

 

 

Then you have to set that as sort by column for your classification column:

Sort by column in Power BI Desktop - Power BI | Microsoft Docs

 

Then the default sort order is according to your sort by column, so "Very high" should appear first.

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 
Anonymous
Not applicable

I've created this measure, but it just can't use a table as refer:

mpoppes_0-1623082552624.png

 

Am I putting the formula in the right place?

Hey @Anonymous ,

 

in general when you answer in this community always mark people with @Anonymous . Otherwise I will not be notified that there is a new reply. This one now I've seen by chance.

 

Did you add it as calculated column? It won't work when you add it as measure.

Then you have to add the column in the right table, in your case I guess 'Pipe espacialistas'. And then you have to replace all the table references (myTable[classification]) to the real column ('Pipe espacialistas'[probabilidade]).

 

Try that and then it hopefully should work.

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

Hi, @Anonymous 

As mentioned by @selimovd ,you should create a calculated column rather than a measure, then sort column by this new calculated colum.

22.png

You can also consider creating  the following sort table  (here you also need to select the column "probability" and sort it by column "column1") . You need to use the field "probability" in this new table to create visual.

 

26.png

Please check my attached file for more details.

 

 

Best Regards,
Community Support Team _ Eason

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.

Top Solution Authors
Top Kudoed Authors