<?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: Running total / cumulative Sales in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107861#M188</link>
    <description>&lt;P&gt;Cool Dude,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We can do ,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Have to add index on your Table using Power Query&amp;nbsp;&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;2. Have to create Calculated Column&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;Let me know if it is not helping u&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 31 Dec 2016 07:11:42 GMT</pubDate>
    <dc:creator>Baskar</dc:creator>
    <dc:date>2016-12-31T07:11:42Z</dc:date>
    <item>
      <title>Running total / cumulative Sales</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107553#M182</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have a requirement to create some Running totals in Power BI, we tried several measures but the results were not as expected.&lt;/P&gt;&lt;P&gt;how can we achieve this in Power BI?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Solution to this problem can be used in multiple scenarios like cumulative sales, Amount Invoiced so far, stock levels etc.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sample Dataset:&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;Sales&lt;/P&gt;&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;STRONG&gt;cumulative Sales&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;10&lt;/P&gt;&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;STRONG&gt;10&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;20&lt;/P&gt;&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;STRONG&gt;30&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;30&lt;/P&gt;&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;STRONG&gt;60&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;40&lt;/P&gt;&lt;/TD&gt;&lt;TD&gt;&lt;P&gt;&lt;STRONG&gt;100&lt;/STRONG&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Happy New Year!!&lt;/P&gt;&lt;P&gt;-Deva&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2016 06:05:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107553#M182</guid>
      <dc:creator>Deva002</dc:creator>
      <dc:date>2016-12-30T06:05:55Z</dc:date>
    </item>
    <item>
      <title>Re: Running total / cumulative Sales</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107572#M185</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="12235" data-lia-user-login="Deva002" class="lia-mention lia-mention-user"&gt;Deva002&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are some similar questions about cummulative with solution like:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;A title="cumulative" href="https://community.fabric.microsoft.com/t5/Desktop/Calculating-Cumulative-Monthly-Totals/m-p/100756#M42247" target="_blank"&gt;Cummulative total&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;&lt;A title="refer" href="https://community.fabric.microsoft.com/t5/Desktop/DAX-How-to-perform-a-cummulative-summation/td-p/7378" target="_blank"&gt;refer topic - cummulative&lt;/A&gt;&lt;/LI&gt;&lt;LI&gt;Full topic:&amp;nbsp;&lt;A href="http://www.daxpatterns.com/time-patterns/" target="_blank"&gt;http://www.daxpatterns.com/time-patterns/&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;With same approach: Create Dates table -&amp;gt; Create measure with filter All(Dates), Dates[Date] &amp;lt;= Max(Dates[Date])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please let me know if you need more sample for your situation.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2016 07:00:44 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107572#M185</guid>
      <dc:creator>tringuyenminh92</dc:creator>
      <dc:date>2016-12-30T07:00:44Z</dc:date>
    </item>
    <item>
      <title>Re: Running total / cumulative Sales</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107604#M186</link>
      <description>&lt;P&gt;Dear&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="8765" data-lia-user-login="tringuyenminh92" class="lia-mention lia-mention-user"&gt;tringuyenminh92&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can we have a measure like this without a date dimension?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;-Deva&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2016 08:55:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107604#M186</guid>
      <dc:creator>Deva002</dc:creator>
      <dc:date>2016-12-30T08:55:35Z</dc:date>
    </item>
    <item>
      <title>Re: Running total / cumulative Sales</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107708#M187</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="12235" data-lia-user-login="Deva002" class="lia-mention lia-mention-user"&gt;Deva002&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sorry for late response cause i just arrived hometown for new year ^_^&lt;/P&gt;&lt;P&gt;One of purposes when using external Dates table to allow you filter another fields in same fact table and the cummulative will be reflected. So if your fact table has only 2 columns &amp;nbsp;Date and Value, i think you could use ALL method and Date column of that.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Cummulative. = CALCULATE(SUM(TableB[Value]),filter(ALL(TableB), TableB[Date]&amp;lt;=MAX(Dates[Date]) ))&lt;/PRE&gt;&lt;P&gt;In case you have additional fields and want to filter on that column, you need to handle with ALLEXCEPT, something like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Cummulative = CALCULATE(SUM(TableB[Value]),filter(ALLEXCEPT(TableB,TableB[AdditionalField/Dim]), TableB[Date]&amp;lt;=MAX(Dates[Date]) ))&lt;/PRE&gt;&lt;P&gt;So my recommendation is using Time Pattern as topic (external dates table):smileyvery-happy:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this works for you please accept it as solution and also like to give KUDOS.&lt;BR /&gt;&lt;BR /&gt;Best regards&lt;BR /&gt;Tri Nguyen&lt;/P&gt;</description>
      <pubDate>Fri, 30 Dec 2016 15:40:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107708#M187</guid>
      <dc:creator>tringuyenminh92</dc:creator>
      <dc:date>2016-12-30T15:40:15Z</dc:date>
    </item>
    <item>
      <title>Re: Running total / cumulative Sales</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107861#M188</link>
      <description>&lt;P&gt;Cool Dude,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We can do ,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Have to add index on your Table using Power Query&amp;nbsp;&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;2. Have to create Calculated Column&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;Let me know if it is not helping u&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 31 Dec 2016 07:11:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Running-total-cumulative-Sales/m-p/107861#M188</guid>
      <dc:creator>Baskar</dc:creator>
      <dc:date>2016-12-31T07:11:42Z</dc:date>
    </item>
  </channel>
</rss>

