<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Measure and sort in matrix in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4733852#M181333</link>
    <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am hoping someone can help with my challenge.&amp;nbsp; I have looked online and I may be overcomplicating my issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screen shot of dashboard&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a measure that allows me to select Year, month, to compare data across years.&amp;nbsp; The matrix you can see has two measures.&amp;nbsp; Both feed from the DAX measure in&amp;nbsp;&lt;A href="https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dynamic-Time-comparison-across-multiple-years/m-p/4721480#M180830" target="_blank"&gt;Solved: Re: Dynamic Time comparison across multiple years - Microsoft Fabric Community&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to order by values in the columns. But when I click on the triangle icon it does not sort correctly.&amp;nbsp; Can I sort my values in a column defined by a measure?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Stuart&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 16 Jun 2025 16:15:03 GMT</pubDate>
    <dc:creator>StuartPQY</dc:creator>
    <dc:date>2025-06-16T16:15:03Z</dc:date>
    <item>
      <title>Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4733852#M181333</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am hoping someone can help with my challenge.&amp;nbsp; I have looked online and I may be overcomplicating my issue.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Screen shot of dashboard&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a measure that allows me to select Year, month, to compare data across years.&amp;nbsp; The matrix you can see has two measures.&amp;nbsp; Both feed from the DAX measure in&amp;nbsp;&lt;A href="https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dynamic-Time-comparison-across-multiple-years/m-p/4721480#M180830" target="_blank"&gt;Solved: Re: Dynamic Time comparison across multiple years - Microsoft Fabric Community&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to order by values in the columns. But when I click on the triangle icon it does not sort correctly.&amp;nbsp; Can I sort my values in a column defined by a measure?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Stuart&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Jun 2025 16:15:03 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4733852#M181333</guid>
      <dc:creator>StuartPQY</dc:creator>
      <dc:date>2025-06-16T16:15:03Z</dc:date>
    </item>
    <item>
      <title>Re: Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4733893#M181334</link>
      <description>&lt;P&gt;You will laugh when I tell you the answer ....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Change the data type from Text to a Number&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Text will sort alphabetically and left justify like this.&lt;/P&gt;&lt;P&gt;The promlem will fix itself when you use a number instead of text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please click thumbs up and accept solution. Thank you !&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;301&lt;/P&gt;&lt;P&gt;32&lt;/P&gt;&lt;P&gt;4&lt;/P&gt;&lt;P&gt;405&lt;/P&gt;&lt;P&gt;43&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Jun 2025 17:01:18 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4733893#M181334</guid>
      <dc:creator>speedramps</dc:creator>
      <dc:date>2025-06-16T17:01:18Z</dc:date>
    </item>
    <item>
      <title>Re: Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734441#M181348</link>
      <description>&lt;P&gt;Hi &lt;A href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/532687" target="_self"&gt;&lt;SPAN class=""&gt;StuartPQY&lt;/SPAN&gt;&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please change the &lt;STRONG&gt;Actuals&lt;/STRONG&gt; column data type as Whole Number.&lt;BR /&gt;Also, you can sort 2 columns by using shift key on keyboard and click one by one column to sort on multiple columns in a visual.&lt;BR /&gt;One more thing, if youare using Text columns in calculations in mesaures then there might chances of error as well.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;If this reply helped solve your problem, please consider clicking "Accept as Solution" so others can benefit too.&amp;nbsp;And if you found it useful, a quick "Kudos" is always appreciated, thanks!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Maruthi&amp;nbsp;&lt;/P&gt;&lt;P&gt;LinkedIn -&amp;nbsp;&lt;A href="http://www.linkedin.com/in/maruthi-siva-prasad/" target="_blank" rel="nofollow noopener noreferrer"&gt;http://www.linkedin.com/in/maruthi-siva-prasad/&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;X&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; -&amp;nbsp;&amp;nbsp;&lt;A href="https://x.com/maruthisp" target="_blank" rel="nofollow noopener noreferrer"&gt;Maruthi Siva Prasad - (@MaruthiSP) / X&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Jun 2025 07:54:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734441#M181348</guid>
      <dc:creator>maruthisp</dc:creator>
      <dc:date>2025-06-17T07:54:50Z</dc:date>
    </item>
    <item>
      <title>Re: Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734477#M181350</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="532687" data-lia-user-login="StuartPQY" class="lia-mention lia-mention-user"&gt;StuartPQY&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Thanks for sharing the screenshot and explaining your challenge. It looks like you're using a &lt;STRONG&gt;matrix visual&lt;/STRONG&gt; in Power BI, displaying two DAX measures: one for &lt;STRONG&gt;Prior Year Actuals&lt;/STRONG&gt; and one for &lt;STRONG&gt;Actuals&lt;/STRONG&gt;. You're trying to &lt;STRONG&gt;sort the matrix by one of these measures&lt;/STRONG&gt;, but the sorting doesn't work as expected. Let's go over why this might be happening and how to fix it.&lt;/P&gt;
&lt;H2&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;There are 3 option to correct sorting&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/H2&gt;
&lt;H2&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;Option 1: Use a Single Dynamic Measure Instead of Two Static Measures&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/H2&gt;
&lt;P&gt;If you're using two separate measures like [Prior Yr Actuals] and [Actuals], consider creating one dynamic measure that returns the correct value based on slicer selections (like year or period offset). This way, you’ll only have one measure in the matrix, which makes sorting much more reliable.&lt;/P&gt;
&lt;H3&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;Option 2: Switch to Table Visual Instead of Matrix&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/H3&gt;
&lt;P&gt;If you don't need the row/column hierarchy provided by the matrix visual:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;
&lt;P&gt;Switch to a table visual, which allows sorting directly by measure columns more reliably.&lt;/P&gt;
&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;Add [Supplier Name], [Prior Yr Actuals], [Actuals] as separate columns.&lt;/P&gt;
&lt;/LI&gt;
&lt;/UL&gt;
&lt;H3&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;Option 3: Use a Sort Column&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/H3&gt;
&lt;P&gt;Create a calculated column to help sorting:&amp;nbsp;SortOrder = SELECTEDMEASURE()&lt;/P&gt;
&lt;P&gt;Then sort the matrix by that measure, using the Sort Order column (you may need to change visual type or tweak formatting).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;For Detailed Information:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.fabric.microsoft.com/t5/Desktop/Sort-Matrix-by-Measure/td-p/142742" target="_new" rel="noopener"&gt;https://community.fabric.microsoft.com/t5/Desktop/Sort-Matrix-by-Measure/td-p/142742&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://community.fabric.microsoft.com/t5/Desktop/Sort-Matrix-by-Value-not-working/td-p/417722" target="_new" rel="noopener"&gt;https://community.fabric.microsoft.com/t5/Desktop/Sort-Matrix-by-Value-not-working/td-p/417722&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;If you found this solution helpful, please consider accepting it and giving it a kudos (Like) it’s greatly appreciated and helps others find the solution more easily.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Best Regards,&lt;BR /&gt;&lt;A href="https://www.linkedin.com/in/nasif-azam-9aa2331a0/" target="_blank" rel="noopener nofollow noreferrer"&gt;Nasif Azam&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 10:11:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734477#M181350</guid>
      <dc:creator>Nasif_Azam</dc:creator>
      <dc:date>2025-06-18T10:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734804#M181355</link>
      <description>&lt;P&gt;&lt;SPAN data-teams="true"&gt;Hi &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="532687" data-lia-user-login="StuartPQY" class="lia-mention lia-mention-user"&gt;StuartPQY&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Thank you for reaching out to the Microsoft Fabric Community. Also thank you&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="177566" data-lia-user-login="speedramps" class="lia-mention lia-mention-user"&gt;speedramps&lt;/a&gt;&amp;nbsp;, &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="526044" data-lia-user-login="maruthisp" class="lia-mention lia-mention-user"&gt;maruthisp&lt;/a&gt;&amp;nbsp;&amp;nbsp;and&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="871356" data-lia-user-login="Nasif_Azam" class="lia-mention lia-mention-user"&gt;Nasif_Azam&lt;/a&gt;&amp;nbsp;&amp;nbsp; for your insights.&lt;/P&gt;
&lt;P&gt;&lt;SPAN data-teams="true"&gt;&lt;BR /&gt;I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN data-teams="true"&gt;&lt;BR /&gt;Thank you.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Jun 2025 12:44:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4734804#M181355</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-06-17T12:44:58Z</dc:date>
    </item>
    <item>
      <title>Re: Measure and sort in matrix</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4735656#M181390</link>
      <description>&lt;P&gt;Hello&lt;BR /&gt;Thank you for the replies.&amp;nbsp; Pologies for the delay in reply, ive not been able to look at this PBI report at work.&amp;nbsp; I will do so today.&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Stuart&lt;/P&gt;</description>
      <pubDate>Wed, 18 Jun 2025 08:45:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-and-sort-in-matrix/m-p/4735656#M181390</guid>
      <dc:creator>StuartPQY</dc:creator>
      <dc:date>2025-06-18T08:45:55Z</dc:date>
    </item>
  </channel>
</rss>

