<?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 Re: DAX total != total rows in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889037#M186140</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="286173" data-lia-user-login="SaaM" class="lia-mention lia-mention-user"&gt;SaaM&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It is likely that your total doesn't work because you have multiple columns which is affecting your filter condition.&amp;nbsp; In order for the sumx solution to work you will need to incorporate all the filter condition columns into your sumx formula.&amp;nbsp; An example of the formula is as shown below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Calcul_incremental_Total = 
SUMX(
    SUMMARIZE(
        'YourTable', 
        'YourTable'[Column1], 
        'YourTable'[Column2]
    ),
    IF([diff_CA] &amp;gt; 0, [diff_CA], 0)
)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;Would you like me to generate the exact dax formula to fix the total? If so, please let me know which columns are currently listed in the rows section of your table visual.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards,&lt;/P&gt;</description>
    <pubDate>Sun, 30 Nov 2025 12:12:33 GMT</pubDate>
    <dc:creator>DataNinja777</dc:creator>
    <dc:date>2025-11-30T12:12:33Z</dc:date>
    <item>
      <title>DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888523#M186118</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have an issue where the total of the rows is not equal to the total calculated in a table, let me explain what I mean:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I calculate first the difference between the CA N and CA N-1 that I store in diff_CA measure&lt;BR /&gt;and I store in Calcul_incremental measure:&lt;/P&gt;&lt;P&gt;- if (diff_CA &amp;gt;0, diff_CA, 0)&lt;/P&gt;&lt;P&gt;and I except the total to be 129 367,62 +0,00 = 129 637.62 and not 129 367.62 -263.86 = 129 103.76&lt;BR /&gt;&lt;BR /&gt;What am I doing wrong here to fix the total taking into account not the values calculated with the condition ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;BR /&gt;Kind regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 15:58:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888523#M186118</guid>
      <dc:creator>SaaM</dc:creator>
      <dc:date>2025-11-28T15:58:32Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888529#M186120</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="286173" data-lia-user-login="SaaM" class="lia-mention lia-mention-user"&gt;SaaM&lt;/a&gt;,&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;DIV class=""&gt;This behaviour is expected because of how DAX calculates totals: &lt;STRONG&gt;the total is not the sum of the row results, but a recalculation of the measure in the total context&lt;/STRONG&gt; (all rows combined). In your case:&lt;/DIV&gt;&lt;UL&gt;&lt;LI&gt;&lt;DIV class=""&gt;For each row:&lt;BR /&gt;Calcul_incremental = IF(diff_CA &amp;gt; 0, diff_CA, 0)&lt;BR /&gt;works correctly because diff_CA is evaluated per row.&lt;/DIV&gt;&lt;/LI&gt;&lt;LI&gt;&lt;DIV class=""&gt;For the total:&lt;BR /&gt;The same formula runs in the &lt;STRONG&gt;grand total context&lt;/STRONG&gt;, where diff_CA is aggregated across all rows first. If the combined diff_CA is negative, the condition fails, and the total shows a smaller value.&lt;/DIV&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please, try something like this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Calcul_incremental =
SUMX(
    VALUES('YourTable'[YourGroupingColumn]),
    IF([diff_CA] &amp;gt; 0, [diff_CA], 0)
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this response was helpful in any way, I’d gladly accept a &lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;much like the joy of seeing a DAX measure work first time without needing another FILTER.&lt;/P&gt;&lt;P&gt;Please mark it as the correct solution. It helps other community members find their way faster (and saves them from another endless loop &lt;span class="lia-unicode-emoji" title=":cyclone:"&gt;🌀&lt;/span&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 16:02:40 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888529#M186120</guid>
      <dc:creator>Zanqueta</dc:creator>
      <dc:date>2025-11-28T16:02:40Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888538#M186121</link>
      <description>&lt;P&gt;unfortunately it is not as I don't get the result expected using the formula suggested:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;How should I proceed to have the total that equals 0.00 + 129367.62&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;Kind regards,&amp;nbsp;&lt;BR /&gt;SaaM&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 16:15:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4888538#M186121</guid>
      <dc:creator>SaaM</dc:creator>
      <dc:date>2025-11-28T16:15:20Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889037#M186140</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="286173" data-lia-user-login="SaaM" class="lia-mention lia-mention-user"&gt;SaaM&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It is likely that your total doesn't work because you have multiple columns which is affecting your filter condition.&amp;nbsp; In order for the sumx solution to work you will need to incorporate all the filter condition columns into your sumx formula.&amp;nbsp; An example of the formula is as shown below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Calcul_incremental_Total = 
SUMX(
    SUMMARIZE(
        'YourTable', 
        'YourTable'[Column1], 
        'YourTable'[Column2]
    ),
    IF([diff_CA] &amp;gt; 0, [diff_CA], 0)
)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;Would you like me to generate the exact dax formula to fix the total? If so, please let me know which columns are currently listed in the rows section of your table visual.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards,&lt;/P&gt;</description>
      <pubDate>Sun, 30 Nov 2025 12:12:33 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889037#M186140</guid>
      <dc:creator>DataNinja777</dc:creator>
      <dc:date>2025-11-30T12:12:33Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889527#M186153</link>
      <description>&lt;P&gt;Thank you so much&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="608865" data-lia-user-login="DataNinja777" class="lia-mention lia-mention-user"&gt;DataNinja777&lt;/a&gt;&amp;nbsp;, your solution works !&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 Dec 2025 10:35:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889527#M186153</guid>
      <dc:creator>SaaM</dc:creator>
      <dc:date>2025-12-01T10:35:31Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889745#M186156</link>
      <description>&lt;P&gt;&lt;BR /&gt;I'm glad you found a solution! We're here in the community to support each other.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;&lt;A href="https://linktr.ee/RufydaRahma" target="_self"&gt;Rufyda Rahma | MIE&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 01 Dec 2025 15:07:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4889745#M186156</guid>
      <dc:creator>Rufyda</dc:creator>
      <dc:date>2025-12-01T15:07:11Z</dc:date>
    </item>
    <item>
      <title>Re: DAX total != total rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4908852#M186564</link>
      <description>&lt;P&gt;Hi &lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="286173" data-lia-user-login="SaaM" class="lia-mention lia-mention-user"&gt;SaaM&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;I hope you are doing well today &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;span class="lia-unicode-emoji" title=":red_heart:"&gt;❤️&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are two solutions you can use to fix the totals issue in your table visual.&lt;/P&gt;&lt;P&gt;Both ensure the total equals the sum of the row values:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 1: Using SUMX with IF&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Calcul_incremental :=
SUMX (
    VALUES ( YourTable[YourRowColumn] ),
    VAR Diff = SUM ( YourTable[CA N] ) - SUM ( YourTable[CA N-1] )                  
    RETURN
        IF ( Diff &amp;gt; 0, Diff, 0 )
)&lt;/LI-CODE&gt;&lt;UL&gt;&lt;LI&gt;Evaluates row by row&lt;/LI&gt;&lt;LI&gt;Applies the condition per row&lt;/LI&gt;&lt;LI&gt;Totals now match the sum of rows&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Solution 2: Using SUMX with MAX (shorter)&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Calcul_incremental :=
SUMX (
VALUES ( YourTable[YourRowColumn] ),
MAX ( SUM ( YourTable[CA N] ) - SUM ( YourTable[CA N-1] ), 0 )
)                          &lt;/LI-CODE&gt;&lt;UL&gt;&lt;LI&gt;Shorter, cleaner syntax&lt;/LI&gt;&lt;LI&gt;Works exactly the same&lt;/LI&gt;&lt;LI&gt;Ensures totals equal the sum of rows&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Work Notes:&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Replace &lt;STRONG&gt;YourTable[YourRowColumn]&lt;/STRONG&gt; with the column that defines each row in your table&lt;/LI&gt;&lt;LI&gt;e.g., Customer, Account, Product&lt;/LI&gt;&lt;LI&gt;Both approaches work for table, matrix, and card visuals&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this answer helped, kindly give &lt;FONT color="#993300"&gt;&lt;STRONG&gt;Kudos&lt;/STRONG&gt;&lt;/FONT&gt; and &lt;FONT color="#993300"&gt;&lt;STRONG&gt;mark it as the Accepted Solution&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;to help other members find it more quickly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Vaibhav Mahajan&lt;/P&gt;&lt;P&gt;LinkedIn: &lt;A href="https://www.linkedin.com/in/vaibhavnmahajan" target="_self"&gt;https://www.linkedin.com/in/vaibhavnmahajan&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Dec 2025 10:34:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/DAX-total-total-rows/m-p/4908852#M186564</guid>
      <dc:creator>vaibhavmahajan</dc:creator>
      <dc:date>2025-12-26T10:34:10Z</dc:date>
    </item>
  </channel>
</rss>

