Public Schedule Face-to-Face & Online Instructor-Led Training - View dates & book

sort order matrix

Forum home » Delegate support and help forum » Microsoft Power BI training and help » Sort order in matrix

Sort order in matrix

ResolvedVersion 365

Sort order in matrix

I have created a separate table with an order for the accounts I am using in rows in a matrix ie revenue = 1, gross profit = 2 etc.
How can I then link the table via a related measure and then sort by the order in the matrix? Nothing I am trying is working! Thanks

RE: Sort order in matrix

Hi Kerri,

Thank you for the forum question.

I do not know your data model, but what I did.

I created a new table. In the table I typed the different groups ( revenue, gross profit etc.).

In the second column I added the index number ( 1 in the first row, 2 in the second etc.). Then I sorted column 1 by the index column.

You will need to create a relationship in your data model from the first column in the new table to your fact table, where you have all the transaction for your revenue, gross profit etc..

If you use the first column from the new table in a matrix you will get it sorted by the index column.

The problem can be that your measure may be just will show the same amount for each group in the matrix.

This will happen if your measure needs to go against the filter direction in your data model (filter from the foreign key to the primary key). If this is an issue you will need the Calculate function to handle this.

I wrote a blog post about this. Please have a look at the link below.

https://www.stl-training.co.uk/b/power-bi-dax-the-mysterious-calculate-function-4-tricks/


Kind regards

Jens Bonde
Microsoft Office Specialist Trainer

Tel: 0207 987 3777
STL - https://www.stl-training.co.uk
98%+ recommend us

London's leader with UK wide delivery in Microsoft Office training and management training to global brands, FTSE 100, SME's and the public sector

Will be marked as resolved in 5 days

Notice: This is an automated message. Due to inactivity, this forum post will be marked as 'resolved' if there are no further responses in the next 5 days.

Thu 18 Jan 2024: Automatically marked as resolved.

 

Training courses

Welcome. Please choose your application (eg. Excel) and then post your question.

Our Microsoft Qualified trainers will then respond within 24 hours (working days).

Frequently Asked Questions
What does 'Resolved' mean?

Any suggestions, questions or comments? Please post in the Improve the forum thread.

Power BI tip:

Scheduled Refresh and Power BI Service

If you're using Power BI Service, set up scheduled refresh for your datasets. This ensures that your reports are always up-to-date with the latest data. Understand the refresh limits imposed by Power BI Service and optimize your data model and queries to stay within those constraints.

View all Power BI hints and tips

Connect with us:

0207 987 3777

Call for assistance

Request Callback

We will call you back

Server loaded in 0.11 secs.