<?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 Data Load - Calculate the difference between cumulative values in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805010#M65404</link>
    <description>&lt;P&gt;Hi -&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not entirely sure if the following can be accomplished.&lt;/P&gt;&lt;P&gt;On the data load, I would like to calculate the difference between values instead of the cumulative value.&lt;/P&gt;&lt;P&gt;That is, by date and location, determine the difference in quantity between the two dates.&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jerryr125_1-1620132962282.png" style="width: 416px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/54226i8A3C0901E4683F2D/image-dimensions/416x475?v=v2" width="416" height="475" role="button" title="jerryr125_1-1620132962282.png" alt="jerryr125_1-1620132962282.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Therefore, the OUTPUT is the results I am attempting to achieve for the data load.&lt;/P&gt;&lt;P&gt;Any thoughts ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks - Jerry&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 04 May 2021 12:58:19 GMT</pubDate>
    <dc:creator>jerryr125</dc:creator>
    <dc:date>2021-05-04T12:58:19Z</dc:date>
    <item>
      <title>Data Load - Calculate the difference between cumulative values</title>
      <link>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805010#M65404</link>
      <description>&lt;P&gt;Hi -&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am not entirely sure if the following can be accomplished.&lt;/P&gt;&lt;P&gt;On the data load, I would like to calculate the difference between values instead of the cumulative value.&lt;/P&gt;&lt;P&gt;That is, by date and location, determine the difference in quantity between the two dates.&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jerryr125_1-1620132962282.png" style="width: 416px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/54226i8A3C0901E4683F2D/image-dimensions/416x475?v=v2" width="416" height="475" role="button" title="jerryr125_1-1620132962282.png" alt="jerryr125_1-1620132962282.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Therefore, the OUTPUT is the results I am attempting to achieve for the data load.&lt;/P&gt;&lt;P&gt;Any thoughts ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks - Jerry&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 May 2021 12:58:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805010#M65404</guid>
      <dc:creator>jerryr125</dc:creator>
      <dc:date>2021-05-04T12:58:19Z</dc:date>
    </item>
    <item>
      <title>Re: Data Load - Calculate the difference between cumulative values</title>
      <link>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805110#M65425</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/24530"&gt;@jerryr125&lt;/a&gt;&amp;nbsp;, you can use the Previous() function to calculate this difference:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;Output:&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;Load&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;&amp;nbsp; &amp;nbsp;Date,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;&amp;nbsp; &amp;nbsp;Location,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;&amp;nbsp; &amp;nbsp;If(Location = Previous(Location), [Quantity Sold Cummulative] - Previous([Quantity Sold Cummulative]),&amp;nbsp;[Quantity Sold Cummulative]) AS&amp;nbsp;[Quantity Sold]&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;Resident Input&amp;nbsp; // Or from your data connection&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier" color="#008000"&gt;Order by Location, Date;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;JG&lt;/P&gt;</description>
      <pubDate>Tue, 04 May 2021 18:55:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805110#M65425</guid>
      <dc:creator>JuanGerardo</dc:creator>
      <dc:date>2021-05-04T18:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: Data Load - Calculate the difference between cumulative values</title>
      <link>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805157#M65432</link>
      <description>&lt;P&gt;Thank you - perfect ! Jerry&lt;/P&gt;</description>
      <pubDate>Tue, 04 May 2021 23:00:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Data-Load-Calculate-the-difference-between-cumulative-values/m-p/1805157#M65432</guid>
      <dc:creator>jerryr125</dc:creator>
      <dc:date>2021-05-04T23:00:01Z</dc:date>
    </item>
  </channel>
</rss>

