<?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: Sum the result of each row the total sum in the total subtotal rows in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2426515#M64466</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="353637" data-lia-user-login="JNMx" class="lia-mention lia-mention-user"&gt;JNMx&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To change the wrong total, please try measure as below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Measure =
SUMX ( VALUES ( Table[Item] ), [Sum IF CY is 0] )&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;BR /&gt;Community Support Team _ Eason&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 06 Apr 2022 02:27:56 GMT</pubDate>
    <dc:creator>v-easonf-msft</dc:creator>
    <dc:date>2022-04-06T02:27:56Z</dc:date>
    <item>
      <title>Sum the result of each row the total sum in the total subtotal rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2416189#M63828</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to get a different result depending on 2 columns:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sales Last Year&lt;/P&gt;&lt;P&gt;Sales Current Year&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if current year sales are 0 I classify this as "Discontinued" and I would like to have a column displaying that in a table.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have achieved this with Dax with no problem BUT check the total row, it displays Zero, and I would like to have the sum of the column "Sum if CY is 0", e.g. -3, -2, -1, -2-&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I understand that the measure I am using will not apply in total because the Sales CY in total is not 0; but I don't know how to sum the rows.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance for your time and attention.&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;</description>
      <pubDate>Thu, 24 Mar 2022 21:02:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2416189#M63828</guid>
      <dc:creator>JNMx</dc:creator>
      <dc:date>2022-03-24T21:02:29Z</dc:date>
    </item>
    <item>
      <title>Re: Sum the result of each row the total sum in the total subtotal rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2416405#M63831</link>
      <description>&lt;P&gt;Hello:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can add a calculated column to your table. I'm calling the table "Data". It just has a bit of conditional logic.&lt;/P&gt;&lt;P&gt;Then a measure to sum up the negatives only. Please see below. I hope this helps!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Calc Col&amp;nbsp; Sum Neg YoY = &lt;/SPAN&gt;&lt;SPAN&gt;IF&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;Data[Var]&lt;/SPAN&gt;&lt;SPAN&gt; &amp;lt; &lt;/SPAN&gt;&lt;SPAN&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;Data[Var]&lt;/SPAN&gt;&lt;SPAN&gt;,&lt;/SPAN&gt;&lt;SPAN&gt;BLANK&lt;/SPAN&gt;&lt;SPAN&gt;())&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;SPAN&gt;Measure&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Neg Var Total = &lt;/SPAN&gt;&lt;SPAN&gt;SUM&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;Data[Sum Neg YoY]&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 24 Mar 2022 23:50:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2416405#M63831</guid>
      <dc:creator>Whitewater100</dc:creator>
      <dc:date>2022-03-24T23:50:52Z</dc:date>
    </item>
    <item>
      <title>Re: Sum the result of each row the total sum in the total subtotal rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2418421#M63933</link>
      <description>&lt;P&gt;Unfortunately those aren't physical columns, those are measures, that's the difficulty.&lt;/P&gt;</description>
      <pubDate>Fri, 25 Mar 2022 16:22:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2418421#M63933</guid>
      <dc:creator>JNMx</dc:creator>
      <dc:date>2022-03-25T16:22:20Z</dc:date>
    </item>
    <item>
      <title>Re: Sum the result of each row the total sum in the total subtotal rows</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2426515#M64466</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="353637" data-lia-user-login="JNMx" class="lia-mention lia-mention-user"&gt;JNMx&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To change the wrong total, please try measure as below:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Measure =
SUMX ( VALUES ( Table[Item] ), [Sum IF CY is 0] )&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;BR /&gt;Community Support Team _ Eason&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Apr 2022 02:27:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Sum-the-result-of-each-row-the-total-sum-in-the-total-subtotal/m-p/2426515#M64466</guid>
      <dc:creator>v-easonf-msft</dc:creator>
      <dc:date>2022-04-06T02:27:56Z</dc:date>
    </item>
  </channel>
</rss>

