Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Change columns order in Matrix

Hello,   I have the following matrix and I want a specific column order:     For the Colum "Market" where I have the Stores, I want them in a specific order. Could you, please, tell me how...
  • Greg_Deckler's avatar
    Greg_Deckler
    6 years ago

    It is going to depend on your data. But, if you have a table in which you have your values for your store identifiers, Store 1, Store 2, Store 3, etc., in Power Query createa a column that looks at those values and produces your sort order, let's say you want:

     

    Store 2

    Store 4

    Store 3

    Store 1

     

    You would create a column, we will call this column "Sort", where if your Store column is Store 2, this column would be 1 and if the Store column is Store 4, 2 and so on.

     

    Then, once you import this data, you would select your Store column. You would go to Column Tools and then Sort by column and choose your new Sort column.

     

    Not sure I can explain the process any better than that.