<?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: Stock Calculation in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542050#M202596</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Arun,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The solution for your problem can be solved by a so called &lt;STRONG&gt;AsOfDate table.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I faced the same problem and was able to solve it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;The AsOf needs changes in the data model to create the AsOf table and fill it with the necessary records. The advantage is that it likely performs better on large data sets. It's also quite versatile since you can add several sets of records to meet different scenario's. The expressions you end up with in the charts are also less complicated. That said, it will likely take you some time to fully understand the AsOf table concept and realize all the places where you can put it to good use.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;The above info is taken from this document: &lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-4252"&gt;http://community.qlik.com/docs/DOC-4252&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;There the concept of an AsOfTable is explained. But in stead of an rolling period you need to built up your table form the first transaction date.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;An example how to build the table can be found here: &lt;A _jive_internal="true" href="https://community.qlik.com/message/93904#93904"&gt;http://community.qlik.com/message/93904#93904 &lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;You should look at the helpful answer of&amp;nbsp; &lt;A href="https://community.qlik.com/qlik-users/2226"&gt;John Witherspoon&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope the concept of AsOfDate will become clear to you.&lt;/P&gt;&lt;P&gt;If you struggle let me know I I will then prepare an example .qvw with an extract of my dataset.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All credits for this solution go to &lt;A href="https://community.qlik.com/qlik-users/2226"&gt;John Witherspoon&lt;/A&gt; and &lt;A href="https://community.qlik.com/qlik-users/96544"&gt;Gysbert Wassenaar&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gerrit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 22 Nov 2013 16:22:59 GMT</pubDate>
    <dc:creator />
    <dc:date>2013-11-22T16:22:59Z</dc:date>
    <item>
      <title>Stock Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542046#M202592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to calculate current stock.&lt;/P&gt;&lt;P&gt;As per calculation , for each date, the current stock is sum of all inventory previous to that date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now i want to show monthly stock in a bar chart.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For 2013 Jan , the stock would be sum of stock quantity previous to 2013-Jan-31&lt;/P&gt;&lt;P&gt;For 2013 Feb , the stock would be sum of stock quantity previous to 2013-Feb-28&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example, in this table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Year, Month, Day, Quantity&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2012, 12, 1, 1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2012, 12, 12, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2012, 12, 18, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2012, 12, 31, -4&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 1, 1, 1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 1, 12, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 1, 18, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 1, 31, 4&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 2, 1, 5, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 2, 12, 4, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 2, 18, 1, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 2, 31, 1&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 3, 1, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 3, 12, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 3, 18, 2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2013, 3, 31, 2&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Stock for 2013 Jan=1+2+2-4&amp;nbsp;&amp;nbsp; +1+2+2+4&lt;/P&gt;&lt;P&gt;Stock for 2013 Feb=1+2+2-4&amp;nbsp; +1+2+2+4&amp;nbsp; +5+4+1+1&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We can calculate individual using set analysis, but how to calculate all at same time for bar chart.&lt;/P&gt;&lt;P&gt;How can i create monthly stock bar chart....&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 05:33:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542046#M202592</guid>
      <dc:creator />
      <dc:date>2013-11-19T05:33:33Z</dc:date>
    </item>
    <item>
      <title>Re: Stock Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542047#M202593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I believe what you want is Full Accumulation (and you will want to make your dimension a date, as right now you only have it as a month):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jiveImage" src="https://community.qlik.com/legacyfs/online/49179_pastedImage_0.png" style="width: 620px; height: 548px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 17:06:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542047#M202593</guid>
      <dc:creator>Nicole-Smith</dc:creator>
      <dc:date>2013-11-19T17:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: Stock Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542048#M202594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi.&lt;/P&gt;&lt;P&gt;&lt;SPAN class="hps"&gt;Check out this discussion, maybe this can help you.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="hps"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/message/423634?et=watches.email.thread#423634"&gt;http://community.qlik.com/message/423634?et=watches.email.thread#423634&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 19:10:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542048#M202594</guid>
      <dc:creator>spividori</dc:creator>
      <dc:date>2013-11-19T19:10:00Z</dc:date>
    </item>
    <item>
      <title>Re: Stock Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542049#M202595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I cannot make dimension a date, i have over 10 years of data (2003-2013), now if user click on 2013, full accumulation will accumulate only 2013 data.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Nov 2013 06:51:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542049#M202595</guid>
      <dc:creator />
      <dc:date>2013-11-20T06:51:10Z</dc:date>
    </item>
    <item>
      <title>Re: Stock Calculation</title>
      <link>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542050#M202596</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Arun,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The solution for your problem can be solved by a so called &lt;STRONG&gt;AsOfDate table.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I faced the same problem and was able to solve it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;The AsOf needs changes in the data model to create the AsOf table and fill it with the necessary records. The advantage is that it likely performs better on large data sets. It's also quite versatile since you can add several sets of records to meet different scenario's. The expressions you end up with in the charts are also less complicated. That said, it will likely take you some time to fully understand the AsOf table concept and realize all the places where you can put it to good use.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;The above info is taken from this document: &lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-4252"&gt;http://community.qlik.com/docs/DOC-4252&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;There the concept of an AsOfTable is explained. But in stead of an rolling period you need to built up your table form the first transaction date.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: verdana, geneva;"&gt;An example how to build the table can be found here: &lt;A _jive_internal="true" href="https://community.qlik.com/message/93904#93904"&gt;http://community.qlik.com/message/93904#93904 &lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;You should look at the helpful answer of&amp;nbsp; &lt;A href="https://community.qlik.com/qlik-users/2226"&gt;John Witherspoon&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope the concept of AsOfDate will become clear to you.&lt;/P&gt;&lt;P&gt;If you struggle let me know I I will then prepare an example .qvw with an extract of my dataset.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All credits for this solution go to &lt;A href="https://community.qlik.com/qlik-users/2226"&gt;John Witherspoon&lt;/A&gt; and &lt;A href="https://community.qlik.com/qlik-users/96544"&gt;Gysbert Wassenaar&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gerrit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Nov 2013 16:22:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Stock-Calculation/m-p/542050#M202596</guid>
      <dc:creator />
      <dc:date>2013-11-22T16:22:59Z</dc:date>
    </item>
  </channel>
</rss>

