<?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 Cumulative inventory in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/737922#M2190</link>
    <description>I am looking for DAX to sum quantity field in Inventory table from the date begining in the database to the end date of every month. This is to know what was the stock available in previous months as option selected as how many months back from current month.&lt;BR /&gt;&lt;BR /&gt;April 2019 -500&lt;BR /&gt;April 2019 - 200&lt;BR /&gt;May 2019 - 600&lt;BR /&gt;Jun 2019. - 100&lt;BR /&gt;&lt;BR /&gt;Dash board would be&lt;BR /&gt;&lt;BR /&gt;April 2019 - 700&lt;BR /&gt;May 2019. - 600&lt;BR /&gt;Jun. 2019 - 1400&lt;BR /&gt;</description>
    <pubDate>Thu, 11 Jul 2019 17:21:49 GMT</pubDate>
    <dc:creator>sinu</dc:creator>
    <dc:date>2019-07-11T17:21:49Z</dc:date>
    <item>
      <title>Cumulative inventory</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/737922#M2190</link>
      <description>I am looking for DAX to sum quantity field in Inventory table from the date begining in the database to the end date of every month. This is to know what was the stock available in previous months as option selected as how many months back from current month.&lt;BR /&gt;&lt;BR /&gt;April 2019 -500&lt;BR /&gt;April 2019 - 200&lt;BR /&gt;May 2019 - 600&lt;BR /&gt;Jun 2019. - 100&lt;BR /&gt;&lt;BR /&gt;Dash board would be&lt;BR /&gt;&lt;BR /&gt;April 2019 - 700&lt;BR /&gt;May 2019. - 600&lt;BR /&gt;Jun. 2019 - 1400&lt;BR /&gt;</description>
      <pubDate>Thu, 11 Jul 2019 17:21:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/737922#M2190</guid>
      <dc:creator>sinu</dc:creator>
      <dc:date>2019-07-11T17:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative inventory</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/739199#M2196</link>
      <description>&lt;P&gt;Your model must have a proper Date table (calendar). Then, you'd do:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Goods in Stock =
var __lastDateVisible = MAX( Calendar[Date] )
return
calculate(
    [Quantity],
    Calendar[Date] &amp;lt;= __lastDateVisible
)&lt;/PRE&gt;&lt;P&gt;where [Quantity] should be a measure that returns the sum of quantity for any selection of attributes from your dimensions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best&lt;/P&gt;&lt;P&gt;Darek&lt;/P&gt;</description>
      <pubDate>Sat, 13 Jul 2019 13:50:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/739199#M2196</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-07-13T13:50:16Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative inventory</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/751495#M2779</link>
      <description>&lt;P&gt;Thank you for the support!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried the option you shared but did not work as expected. I am looking for an option to do inventory analysis for the last 'n' months seletced.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Item A&lt;/P&gt;&lt;P&gt;Item B&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Item A - 100- March 2nd 2017&lt;/P&gt;&lt;P&gt;Item B&amp;nbsp; - 200 - March 5th 2017&lt;/P&gt;&lt;P&gt;Item A - 300&amp;nbsp; - May&amp;nbsp; 15th&amp;nbsp; 2018&lt;/P&gt;&lt;P&gt;Item A -&amp;nbsp; 400 - Dec&amp;nbsp;&amp;nbsp; 20th&amp;nbsp; 2018&lt;/P&gt;&lt;P&gt;Item A -&amp;nbsp; 500 - April&amp;nbsp; 30th 2019&lt;/P&gt;&lt;P&gt;Item A - 400&amp;nbsp; - May&amp;nbsp;&amp;nbsp; 14th&amp;nbsp; 2019&lt;/P&gt;&lt;P&gt;Item A&amp;nbsp; - 200&amp;nbsp; - Jun&amp;nbsp;&amp;nbsp;&amp;nbsp; 12th&amp;nbsp; 2019&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am expecting an output as follows if I need to do analysis from july to back April 2019&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;April 2019&amp;nbsp; - 1500(100+200+300+400+500)&lt;/P&gt;&lt;P&gt;May 2019&amp;nbsp;&amp;nbsp; - 1500+400=1900&lt;/P&gt;&lt;P&gt;Jun 2019&amp;nbsp;&amp;nbsp;&amp;nbsp; -1900+200&amp;nbsp; = 2100&lt;/P&gt;&lt;P&gt;July 2019&amp;nbsp;&amp;nbsp; - 2100+0&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = 2100&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It need's to consider the entires from the very begining date to the end of months displays.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jul 2019 13:04:15 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Cumulative-inventory/m-p/751495#M2779</guid>
      <dc:creator>sinu</dc:creator>
      <dc:date>2019-07-29T13:04:15Z</dc:date>
    </item>
  </channel>
</rss>

