<?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 based on previous data in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910820#M1218122</link>
    <description>&lt;P&gt;one solution might be:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MarcoWedel_0-1648497516700.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/75520iD39541F52A4A5226/image-size/large?v=v2&amp;amp;px=999" role="button" title="MarcoWedel_0-1648497516700.png" alt="MarcoWedel_0-1648497516700.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;table1:
LOAD TransactionDate,
     TransactionID,
     DailyInterest,
     RangeSum(Peek(Interest),Previous(DailyInterest)) as Interest
Inline [
TransactionDate,TransactionID,DailyInterest 
27/03/2022,1115700004,112.83
28/03/2022,1115700004,0.79
29/03/2022,1115700004,0.72
30/03/2022,1115700004,0.71
31/03/2022,1115700004,0.75
01/04/2022,1115700004
];	&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;hope this helps&lt;/P&gt;
&lt;P&gt;Marco&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 28 Mar 2022 19:59:39 GMT</pubDate>
    <dc:creator>MarcoWedel</dc:creator>
    <dc:date>2022-03-28T19:59:39Z</dc:date>
    <item>
      <title>Sum based on previous data</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910496#M1218105</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to sum using previous data. That is adding the previous Daily interest to the Interest&amp;nbsp; for each current day.&lt;/P&gt;
&lt;P&gt;So, 112.83 +&amp;nbsp;0.79 =&amp;nbsp;113.62&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any ideas guys please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Sample&lt;/STRONG&gt;&lt;/P&gt;
&lt;TABLE width="471"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="110"&gt;Transaction Date&amp;nbsp;&lt;/TD&gt;
&lt;TD width="106"&gt;Transaction ID&amp;nbsp;&lt;/TD&gt;
&lt;TD width="125"&gt;Interest&amp;nbsp;&lt;/TD&gt;
&lt;TD width="130"&gt;&lt;A href="https://www.investopedia.com/ask/answers/040315/what-does-it-mean-when-interest-accrues-daily.asp" target="_blank" rel="noopener"&gt;Daily Interest&amp;nbsp;&lt;/A&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;28/03/2022&lt;/TD&gt;
&lt;TD&gt;1115700004&lt;/TD&gt;
&lt;TD&gt;112.83&lt;/TD&gt;
&lt;TD&gt;0.79&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Desired Result&lt;/STRONG&gt;&lt;/P&gt;
&lt;TABLE width="471"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="110"&gt;Transaction Date&amp;nbsp;&lt;/TD&gt;
&lt;TD width="106"&gt;Transaction ID&amp;nbsp;&lt;/TD&gt;
&lt;TD width="125"&gt;Interest&amp;nbsp;&lt;/TD&gt;
&lt;TD width="130"&gt;&lt;A href="https://www.investopedia.com/ask/answers/040315/what-does-it-mean-when-interest-accrues-daily.asp" target="_blank" rel="noopener"&gt;Daily Interest&amp;nbsp;&lt;/A&gt;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;29/03/2022&lt;/TD&gt;
&lt;TD&gt;1115700004&lt;/TD&gt;
&lt;TD&gt;113.62&lt;/TD&gt;
&lt;TD&gt;0.72&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&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;</description>
      <pubDate>Mon, 28 Mar 2022 10:32:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910496#M1218105</guid>
      <dc:creator>Kwame</dc:creator>
      <dc:date>2022-03-28T10:32:04Z</dc:date>
    </item>
    <item>
      <title>Re: Sum based on previous data</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910538#M1218110</link>
      <description>&lt;P&gt;Yes you should be able to do this at load using the Peek function :&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/qlikview/May2021/Subsystems/Client/Content/QV_QlikView/Scripting/InterRecordFunctions/Peek.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/May2021/Subsystems/Client/Content/QV_QlikView/Scripting/InterRecordFunctions/Peek.htm&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Mar 2022 11:30:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910538#M1218110</guid>
      <dc:creator>dmac1971</dc:creator>
      <dc:date>2022-03-28T11:30:12Z</dc:date>
    </item>
    <item>
      <title>Re: Sum based on previous data</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910820#M1218122</link>
      <description>&lt;P&gt;one solution might be:&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="MarcoWedel_0-1648497516700.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/75520iD39541F52A4A5226/image-size/large?v=v2&amp;amp;px=999" role="button" title="MarcoWedel_0-1648497516700.png" alt="MarcoWedel_0-1648497516700.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;table1:
LOAD TransactionDate,
     TransactionID,
     DailyInterest,
     RangeSum(Peek(Interest),Previous(DailyInterest)) as Interest
Inline [
TransactionDate,TransactionID,DailyInterest 
27/03/2022,1115700004,112.83
28/03/2022,1115700004,0.79
29/03/2022,1115700004,0.72
30/03/2022,1115700004,0.71
31/03/2022,1115700004,0.75
01/04/2022,1115700004
];	&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;hope this helps&lt;/P&gt;
&lt;P&gt;Marco&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Mar 2022 19:59:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1910820#M1218122</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2022-03-28T19:59:39Z</dc:date>
    </item>
    <item>
      <title>Re: Sum based on previous data</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1915026#M1218329</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/675"&gt;@MarcoWedel&lt;/a&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Just out of curiosity, how would this script "RangeSum(Peek(Interest),Previous(DailyInterest))" be translated into an expression in a chart type, Many thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Apr 2022 10:49:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1915026#M1218329</guid>
      <dc:creator>Kwame</dc:creator>
      <dc:date>2022-04-06T10:49:21Z</dc:date>
    </item>
    <item>
      <title>Re: Sum based on previous data</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1915029#M1218330</link>
      <description>&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/675"&gt;@MarcoWedel&lt;/a&gt;&amp;nbsp; look at&amp;nbsp;&lt;A href="https://help.qlik.com/en-US/qlikview/May2021/Subsystems/Client/Content/QV_QlikView/ChartFunctions/InterRecordFunctions/above.htm" target="_blank"&gt;https://help.qlik.com/en-US/qlikview/May2021/Subsystems/Client/Content/QV_QlikView/ChartFunctions/InterRecordFunctions/above.htm&lt;/A&gt;&amp;nbsp;it should help.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Apr 2022 10:50:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-based-on-previous-data/m-p/1915029#M1218330</guid>
      <dc:creator>dmac1971</dc:creator>
      <dc:date>2022-04-06T10:50:23Z</dc:date>
    </item>
  </channel>
</rss>

