<?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 Rolled Sum in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197213#M56979</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You could try to run a sum for all year minus sum for the month N-1 ?&lt;/P&gt;&lt;P&gt;using set analysis ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 28 Dec 2009 15:20:58 GMT</pubDate>
    <dc:creator />
    <dc:date>2009-12-28T15:20:58Z</dc:date>
    <item>
      <title>Rolled Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197212#M56978</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;I have some data from Jan 2007 to Dec 2009. I need to display a chart/straight table where the dimension will be the month and expression will be the year 2008 and 2009.&lt;/P&gt;&lt;P&gt;For year 2008 Jan month, I need the sum of Feb 2007 to Jan 2008 and for feb month in 2008, I need the sum of Mar 2007 to Feb 2008 and so on.&lt;/P&gt;&lt;P&gt;I tried the below code but I am not getting the correct sum. Find the data below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Period=, Months={"$(='&amp;lt;='&amp;amp;Only(Months)&amp;amp;'&amp;gt;'&amp;amp;Only(addmonths(Months,-12)))"} &amp;gt;} Amount )&lt;/P&gt;&lt;P&gt;data&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" style="width: 96pt; border-collapse: collapse;" width="128"&gt;&lt;COLGROUP&gt;&lt;COL span="2" style="width: 48pt;" width="64" /&gt;&lt;/COLGROUP&gt;&lt;TBODY&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD height="17" style="width: 48pt; height: 12.75pt; background-color: transparent; border: #ece9d8;" width="64"&gt;Months&lt;/TD&gt;&lt;TD style="width: 48pt; background-color: transparent; border: #ece9d8;" width="64"&gt;Amount&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39083"&gt;Jan-07&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;7276&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39114"&gt;Feb-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;9071&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39142"&gt;Mar-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;7888&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39173"&gt;Apr-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;8583&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39203"&gt;May-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;7721&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39234"&gt;Jun-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;7876&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39264"&gt;Jul-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;7526&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39295"&gt;Aug-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;8049.1&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39326"&gt;Sep-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;7763&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39356"&gt;Oct-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;8064&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39387"&gt;Nov-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;9150&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39417"&gt;Dec-07&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;9144&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39448"&gt;Jan-08&lt;/TD&gt;&lt;TD align="right" class="xl23" style="background-color: transparent; border: #ece9d8;"&gt;&lt;STRONG&gt;11195&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39479"&gt;Feb-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9858&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39508"&gt;Mar-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;10801&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39539"&gt;Apr-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9895&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39569"&gt;May-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;10796&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39600"&gt;Jun-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;11864&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39630"&gt;Jul-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8902&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39661"&gt;Aug-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9130&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39692"&gt;Sep-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9483&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39722"&gt;Oct-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9020&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39753"&gt;Nov-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9569&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39783"&gt;Dec-08&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;10792&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39814"&gt;Jan-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;4317&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39845"&gt;Feb-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8504&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39873"&gt;Mar-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8381&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39904"&gt;Apr-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;10101&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39934"&gt;May-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9325&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39965"&gt;Jun-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;13515&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="39995"&gt;Jul-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8675&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="40026"&gt;Aug-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8803&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="40057"&gt;Sep-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;7048&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="40087"&gt;Oct-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;8691&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="40118"&gt;Nov-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9159&lt;/TD&gt;&lt;/TR&gt;&lt;TR height="17" style="height: 12.75pt;"&gt;&lt;TD align="right" class="xl22" height="17" style="height: 12.75pt; background-color: transparent; border: #ece9d8;" num="40148"&gt;Dec-09&lt;/TD&gt;&lt;TD align="right" style="background-color: transparent; border: #ece9d8;"&gt;9673&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Hope someone can help me&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Sajeevan&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Dec 2009 14:47:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197212#M56978</guid>
      <dc:creator />
      <dc:date>2009-12-28T14:47:25Z</dc:date>
    </item>
    <item>
      <title>Rolled Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197213#M56979</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You could try to run a sum for all year minus sum for the month N-1 ?&lt;/P&gt;&lt;P&gt;using set analysis ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Dec 2009 15:20:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197213#M56979</guid>
      <dc:creator />
      <dc:date>2009-12-28T15:20:58Z</dc:date>
    </item>
    <item>
      <title>Rolled Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197214#M56980</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Can you share how the code will be?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sajeevan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Dec 2009 15:31:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197214#M56980</guid>
      <dc:creator />
      <dc:date>2009-12-28T15:31:31Z</dc:date>
    </item>
    <item>
      <title>Rolled Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197215#M56981</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sajeevan,&lt;/P&gt;&lt;P&gt;First you need to make sure that the Months field is in a proper date format. I added a preceding load to your table in the script:&lt;/P&gt;&lt;P&gt;Data:&lt;BR /&gt;Load&lt;BR /&gt; date(date#(Months,'MMM-YY'),'MMM-YY') as Months,&lt;BR /&gt; Amount;&lt;BR /&gt;LOAD * INLINE [&lt;BR /&gt; Months, Amount&lt;BR /&gt; Jan-07, 7276&lt;BR /&gt; Feb-07, 9071&lt;BR /&gt; Mar-07, 7888&lt;BR /&gt; Apr-07, 8583&lt;/P&gt;&lt;P&gt;etc.&lt;/P&gt;&lt;P&gt;Then you should be able to use an expression like this:&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Period=, Months={"$(='&amp;lt;='&amp;amp;Only(Months) &amp;amp; '&amp;gt;' &amp;amp; only(date(addmonths(Months,-12),'MMM-YY')))"} &amp;gt;} Amount )&lt;/P&gt;&lt;P&gt;Notice that I've added another date() around the addmonths() function. This is because the addmonths() function will format the date value as a full date with days included and we want to strip it down to MMM-YY.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Dec 2009 15:48:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197215#M56981</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2009-12-28T15:48:29Z</dc:date>
    </item>
    <item>
      <title>Rolled Sum</title>
      <link>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197216#M56982</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Johannes,&lt;/P&gt;&lt;P&gt;Thanks for your response. I have the proper date format in Months field. I am not getting the desired result with this expression even after adding the date formating while loading and in the expression. Ideally the rolled sum should have been 102,030 for the month Jan in year 2008 (Feb-07 to Jan-08) but I am getting 22,788.&lt;/P&gt;&lt;P&gt;I think this expression will work only if I select a month otherwise it shows Months={"&amp;lt;=&amp;gt;"}. I am not providing a month selection for the user. If I select the month as Jan-08 then the expression shows Months={"&amp;lt;=Jan-08&amp;gt;Feb-07"} and the rolled sum is only for Jan-08&lt;/P&gt;&lt;P&gt;What I wanted in my chart is&lt;/P&gt;&lt;P&gt;- the dimention month(Months)&lt;/P&gt;&lt;P&gt;- expression for year 2008&lt;/P&gt;&lt;P&gt;- expression for year 2009&lt;/P&gt;&lt;P&gt;I don't know how to attach my QVW file in this mail. I have both versions 8.5 and 9.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Dec 2009 16:53:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Rolled-Sum/m-p/197216#M56982</guid>
      <dc:creator />
      <dc:date>2009-12-28T16:53:02Z</dc:date>
    </item>
  </channel>
</rss>

