<?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: Cumulative Sum across periods with reset in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499542#M103010</link>
    <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/203187"&gt;@Diinkant&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Are you expecting the output below for your query?&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="pallavi_96_0-1735535983106.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/176094i694CE6567F226BF0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="pallavi_96_0-1735535983106.png" alt="pallavi_96_0-1735535983106.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;If yes, please use the following expression&lt;/P&gt;
&lt;P&gt;sum(Aggr(RangeSum(Above(sum(Activity), 0, RowNo())), AccountCode,PeriodID))&lt;/P&gt;</description>
    <pubDate>Mon, 30 Dec 2024 05:21:56 GMT</pubDate>
    <dc:creator>pallavi_96</dc:creator>
    <dc:date>2024-12-30T05:21:56Z</dc:date>
    <item>
      <title>Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499388#M102982</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I am trying to create a cumulative sum across various periods within a financial year but running into a few issues. Image of my data set below.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Diinkant_0-1735253406157.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/176071i2BEF048EAF602E7C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Diinkant_0-1735253406157.png" alt="Diinkant_0-1735253406157.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;In the above image you can see the activity is the same as the cumulative sum, but that shouldn't be the case.&lt;/P&gt;
&lt;P&gt;The formula I have tried&lt;BR /&gt;-&amp;nbsp;RangeSum(&lt;BR /&gt;Above( &lt;BR /&gt;Sum({&lt;BR /&gt;&amp;lt;PeriodID = {"&amp;gt;=$(vLastYearStartPeriod)&amp;lt;=$(vLastYearEndPeriod)"}&amp;gt; &lt;BR /&gt;} [Transaction Amount]),&lt;BR /&gt;0,&lt;BR /&gt;RowNo()&lt;BR /&gt;)&lt;BR /&gt;)&lt;/P&gt;
&lt;P&gt;Keep in mind that another dimension is called account code. So, when it goes into a new account code, the cumulative sum should reset to whatever the activity number is.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Dec 2024 22:52:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499388#M102982</guid>
      <dc:creator>Diinkant</dc:creator>
      <dc:date>2024-12-26T22:52:19Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499401#M102985</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/203187"&gt;@Diinkant&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you please share the dataset that includes the AccountCode for further clarification?&lt;/P&gt;</description>
      <pubDate>Fri, 27 Dec 2024 05:17:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499401#M102985</guid>
      <dc:creator>pallavi_96</dc:creator>
      <dc:date>2024-12-27T05:17:15Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499532#M103009</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/102068"&gt;@pallavi_96&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The accountcode would like this (with the ideal outcome):&lt;/P&gt;
&lt;P&gt;AccountCode | PeriodID | Activity | Cumulative | FiscalYear&lt;/P&gt;
&lt;P&gt;1110.000 | 2701| 10 | 10 | 2022-2023&lt;/P&gt;
&lt;P&gt;1110.000 | 2702 | 20 | 30 | 2022-2023&lt;/P&gt;
&lt;P&gt;1120.000 | 2701 | 10 | 10 | 2022-2023&lt;/P&gt;
&lt;P&gt;1120.000 | 2702 | 30 | 40 | 2022-2023&lt;/P&gt;
&lt;P&gt;1110.000 | 2801 | 20 | 20 | 2023-2024&lt;/P&gt;
&lt;P&gt;The cumulative sum should be a sum for that account code across that fiscal year but break down per period.&lt;/P&gt;</description>
      <pubDate>Sun, 29 Dec 2024 19:53:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499532#M103009</guid>
      <dc:creator>Diinkant</dc:creator>
      <dc:date>2024-12-29T19:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499542#M103010</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/203187"&gt;@Diinkant&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Are you expecting the output below for your query?&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="pallavi_96_0-1735535983106.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/176094i694CE6567F226BF0/image-size/medium?v=v2&amp;amp;px=400" role="button" title="pallavi_96_0-1735535983106.png" alt="pallavi_96_0-1735535983106.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;If yes, please use the following expression&lt;/P&gt;
&lt;P&gt;sum(Aggr(RangeSum(Above(sum(Activity), 0, RowNo())), AccountCode,PeriodID))&lt;/P&gt;</description>
      <pubDate>Mon, 30 Dec 2024 05:21:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499542#M103010</guid>
      <dc:creator>pallavi_96</dc:creator>
      <dc:date>2024-12-30T05:21:56Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499594#M103015</link>
      <description>&lt;P&gt;Thanks for that recommendation but that doesn't work either.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For Example, here are the results with the last column being the formula.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Diinkant_0-1735591947518.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/176103i9E7F43C215EAECB8/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Diinkant_0-1735591947518.png" alt="Diinkant_0-1735591947518.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Dec 2024 20:53:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499594#M103015</guid>
      <dc:creator>Diinkant</dc:creator>
      <dc:date>2024-12-30T20:53:15Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499680#M103024</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/203187"&gt;@Diinkant&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;I used the same formula on your dataset, and it gave me the correct cumulative values for account code 1210.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="pallavi_96_0-1735794219488.png" style="width: 400px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/176123i9E1BD66D30D40936/image-size/medium?v=v2&amp;amp;px=400" role="button" title="pallavi_96_0-1735794219488.png" alt="pallavi_96_0-1735794219488.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jan 2025 05:04:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499680#M103024</guid>
      <dc:creator>pallavi_96</dc:creator>
      <dc:date>2025-01-02T05:04:56Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499830#M103035</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/102068"&gt;@pallavi_96&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks, I have tried it with this dataset&amp;nbsp;&lt;BR /&gt;Test:&lt;BR /&gt;Load * Inline [&lt;BR /&gt;Transaction Date,Account Code,FiscalYear,PeriodID,Transaction Amount&lt;BR /&gt;9-10-2022,1120.000,2022-2023,2701,100&lt;BR /&gt;10-10-2022,1120.000,2022-2023,2701,150&lt;BR /&gt;11-10-2022,1120.000,2022-2023,2701,200&lt;BR /&gt;9-11-2022,1120.000,2022-2023,2702,200&lt;BR /&gt;10-11-2022,1120.000,2022-2023,2702,300&lt;BR /&gt;11-11-2022,1120.000,2022-2023,2702,400&lt;BR /&gt;9-12-2022,1120.000,2022-2023,2703,300&lt;BR /&gt;10-12-2023,1120.000,2023-2024,2801,250&lt;BR /&gt;11-12-2023,1120.000,2023-2024,2802,350&lt;BR /&gt;1-10-2022,1121.000,2022-2023,2701,150&lt;BR /&gt;2-10-2022,1121.000,2022-2023,2701,250&lt;BR /&gt;3-10-2022,1121.000,2022-2023,2701,350&lt;BR /&gt;1-11-2022,1121.000,2022-2023,2702,150&lt;BR /&gt;1-11-2022,1121.000,2022-2023,2702,250&lt;BR /&gt;2-12-2022,1121.000,2022-2023,2702,50&lt;BR /&gt;9-12-2023,1121.000,2023-2024,2801,100&lt;BR /&gt;]; &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It works.&lt;/P&gt;
&lt;P&gt;So, there must be something with the way I am loading my actual data as it works with test data.&lt;/P&gt;
&lt;P&gt;Do I need to order my data in a specific way for it to work within the load script like I have with the test data. This is my load script:&lt;/P&gt;
&lt;P&gt;Transactions:&lt;BR /&gt;[Account Code],&lt;BR /&gt;[Branch Code],&lt;BR /&gt;[Department Code],&lt;BR /&gt;PeriodID,&lt;BR /&gt;[Transaction Amount],&lt;BR /&gt;Month(Date(Date#([Transaction Date],'YYYY-MM-DD'),'DD/MM/YYYY')) as Month,&lt;BR /&gt;MonthName(Date(Date#([Transaction Date],'YYYY-MM-DD'),'DD/MM/YYYY')) as MonthName,&lt;BR /&gt;Year(Date(Date#([Transaction Date],'YYYY-MM-DD'),'DD/MM/YYYY')) as Year,&lt;BR /&gt;YearName(Date(Date#([Transaction Date],'YYYY-MM-DD'),'DD/MM/YYYY'), 0, 7) as FiscalYear,&lt;BR /&gt;[Transaction Date]&lt;/P&gt;
&lt;P&gt;From [Transactions.qvd] (qvd);&lt;/P&gt;</description>
      <pubDate>Thu, 02 Jan 2025 19:52:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499830#M103035</guid>
      <dc:creator>Diinkant</dc:creator>
      <dc:date>2025-01-02T19:52:10Z</dc:date>
    </item>
    <item>
      <title>Re: Cumulative Sum across periods with reset</title>
      <link>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499850#M103036</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/203187"&gt;@Diinkant&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;Please try to sort the 'Account Code' column in the table.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2025 05:11:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cumulative-Sum-across-periods-with-reset/m-p/2499850#M103036</guid>
      <dc:creator>pallavi_96</dc:creator>
      <dc:date>2025-01-03T05:11:10Z</dc:date>
    </item>
  </channel>
</rss>

