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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
DagdasAlbag
Helper I
Helper I

Sorting in the crosstab (column 1)

Hello,

how do I get the sorting in column 1 (year 2021) descending in a crosstab?

The sorting refers to the total column, see Figure 2.

DagdasAlbag_0-1644575014822.png

DagdasAlbag_1-1644575383403.png

 

 

1 ACCEPTED SOLUTION

@DagdasAlbag  I meant like this, needing to create explicit measures for each year: 

 

AllisonKennedy_0-1644580966093.png

 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

View solution in original post

6 REPLIES 6
DagdasAlbag
Helper I
Helper I

Thank you for your answer!
Unfortunately, there is no solution to my question.

Sorry, I forgot there's no 'tooltip' fields for matrix and tables so the workaround I use for other visuals sorting doesn't work here. I've added another reply that is long but will work. 🙂 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

AllisonKennedy
Super User
Super User

@DagdasAlbag  You haven't provided a lot of detail, but if I understand correctly, you can add a measure or column to the tooltips and that will enable you to select it in the 'filters on this visual'. 

 

So add a measure for the value you want to sort by: 

 

2019 Measure = CALCULATE ( [Measure], DimDate[Date] = 2019) 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

DagdasAlbag_0-1644577258782.png

Unfortunately it did not work

@DagdasAlbag  I meant like this, needing to create explicit measures for each year: 

 

AllisonKennedy_0-1644580966093.png

 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

amitchandak
Super User
Super User

@DagdasAlbag , if you are using a  column in matrix, you can only sort on the grand total of values or on row column

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

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

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.