<?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: YTD Computation in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589895#M218747</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Write like below and yes take Cost per month in sum part&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Sum({&amp;lt;Year={"$(=Max(Year))"},&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: inherit;"&gt;MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;EM style="font-weight: inherit; font-family: inherit;"&gt;&amp;gt;} [fieldname] * [cost per month]&lt;EM style="font-weight: inherit; font-family: inherit;"&gt;)&lt;/EM&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Apr 2014 06:28:05 GMT</pubDate>
    <dc:creator>its_anandrjs</dc:creator>
    <dc:date>2014-04-02T06:28:05Z</dc:date>
    <item>
      <title>YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589893#M218745</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;&lt;/P&gt;&lt;P&gt;Just gonna ask a question regarding the computation of YTD.&lt;/P&gt;&lt;P&gt;We all know that getting the YTD we'll be using a set analysis that limits the year,month,quarter..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Sum({&amp;lt;Year={$(=Max(Year))},&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;&lt;EM&gt;&amp;gt;} [fieldname])&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Problem:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since I'll be multiplying this formula to a specific field, let us say [cost per month], which gives me the&lt;/P&gt;&lt;P&gt;formula now to:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;(sum(amount) - Sum({&amp;lt;Year={$(=Max(Year))},&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;&amp;gt;} [fieldname])) * [cost per month]&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Now, my [cost per month] is different per Month. let's say i tick the month of March.. the formula gives me the YTD (Jan,Feb and March totals) but since I tick March, it will only get the [cost per month] of March. How can I get the [cost per month] of Jan and Feb?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;What approach should I do?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;Thanks in advance,&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Donna&lt;EM&gt;&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 06:20:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589893#M218745</guid>
      <dc:creator />
      <dc:date>2014-04-02T06:20:29Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589894#M218746</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try Like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Sum({&amp;lt;Year={$(=Max(Year))},&lt;SPAN style="font-size: 10pt;"&gt;MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;EM&gt;&amp;gt;} &lt;STRONG&gt;[fieldname] * [cost per month]&lt;/STRONG&gt; )&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;I.e. take the [cost per month] part inside of sum().&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 06:23:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589894#M218746</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2014-04-02T06:23:42Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589895#M218747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Write like below and yes take Cost per month in sum part&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Sum({&amp;lt;Year={"$(=Max(Year))"},&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 10pt; font-family: inherit;"&gt;MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&lt;/SPAN&gt;&lt;/EM&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;EM style="font-weight: inherit; font-family: inherit;"&gt;&amp;gt;} [fieldname] * [cost per month]&lt;EM style="font-weight: inherit; font-family: inherit;"&gt;)&lt;/EM&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 06:28:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589895#M218747</guid>
      <dc:creator>its_anandrjs</dc:creator>
      <dc:date>2014-04-02T06:28:05Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589896#M218748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/qlik-users/26418"&gt;tresesco&lt;/A&gt; and &lt;A href="https://community.qlik.com/qlik-users/54627"&gt;Anand Chauhan&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Unfortunately this doesn't work as this will alter my formula.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my original formula is getting the (amount-formula above)*[costpermonth]/1000.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;will update the details on the post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2014 07:37:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589896#M218748</guid>
      <dc:creator />
      <dc:date>2014-04-02T07:37:08Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589897#M218749</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;bump&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 01:28:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589897#M218749</guid>
      <dc:creator />
      <dc:date>2014-04-03T01:28:59Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589898#M218750</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;bump&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 04:49:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589898#M218750</guid>
      <dc:creator />
      <dc:date>2014-04-03T04:49:10Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589899#M218751</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you post a sample app explaining expected output there?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 04:51:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589899#M218751</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2014-04-03T04:51:56Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589900#M218752</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 can only send a visual on excel, below is an example for Jan-Feb&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" style="width: 983px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl67" height="17" width="97"&gt;Month&lt;/TD&gt;&lt;TD class="xl68" style="border-left: none;" width="131"&gt;Amt_Final&lt;/TD&gt;&lt;TD class="xl68" style="border-left: none;" width="103"&gt;Volume&lt;/TD&gt;&lt;TD class="xl67" style="border-left: none;" width="124"&gt;Total Cost of Sales&lt;/TD&gt;&lt;TD class="xl69" style="border-left: none;" width="276"&gt;Amt_Final - Volume*Total Cost&lt;/TD&gt;&lt;TD class="xl70" style="border-left: none;" width="252"&gt;(Amt_Final - Volume*Total Cost) / Volume&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl67" height="17" style="border-top: none;"&gt;Jan&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1,341,542,456&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 30,325,290&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: none; border-left: none;"&gt;42.76&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;"&gt;44,833,055.60&lt;/TD&gt;&lt;TD align="right" class="xl71" style="border-top: none; border-left: none;"&gt;1.006122705&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl67" height="17" style="border-top: none;"&gt;Feb&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1,379,869,091&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 32,547,091&lt;/TD&gt;&lt;TD align="right" class="xl67" style="border-top: none; border-left: none;"&gt;41.83&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;"&gt;18,424,274.47&lt;/TD&gt;&lt;TD class="xl67" style="border-top: none; border-left: none;"&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since in qlikview we sum up the totals:&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" style="width: 983px;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl71" height="17" width="97"&gt;&lt;P&gt;Qlikview&lt;/P&gt;&lt;P&gt;Month (YTD)&lt;/P&gt;&lt;/TD&gt;&lt;TD class="xl68" style="border-left: none;" width="131"&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Amt_Final&lt;/P&gt;&lt;/TD&gt;&lt;TD class="xl68" style="border-left: none;" width="103"&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Volume&lt;/P&gt;&lt;/TD&gt;&lt;TD class="xl67" style="border-left: none;" width="124"&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Total Cost of Sales&lt;/P&gt;&lt;/TD&gt;&lt;TD class="xl69" style="border-left: none;" width="276"&gt;Amt_Final - Volume*SUM(Total Cost of Sales)&lt;/TD&gt;&lt;TD class="xl67" style="border-left: none;" width="252"&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl71" height="17" style="border-top: none;"&gt;Jan-Feb&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2,721,411,547&lt;/TD&gt;&lt;TD class="xl68" style="border-top: none; border-left: none;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 62,782,381&lt;/TD&gt;&lt;TD align="right" class="xl73" style="border-top: none; border-left: none;"&gt;?&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;"&gt;&lt;/TD&gt;&lt;TD align="right" class="xl72" style="border-top: none; border-left: none;"&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 05:06:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589900#M218752</guid>
      <dc:creator />
      <dc:date>2014-04-03T05:06:50Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589901#M218753</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;Assuming month is the only dimension in the table, I suggest&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Sum(Aggr((Sum(amount) - Sum({&amp;lt;Year={$(=Max(Year))},MonthNum = {"&amp;lt;=$(=Max(MonthNum))"}, Month=, Quarter=&amp;gt;} [fieldname])) * [cost per month], Month))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 05:32:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589901#M218753</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2014-04-03T05:32:58Z</dc:date>
    </item>
    <item>
      <title>Re: YTD Computation</title>
      <link>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589902#M218754</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Year={$(=(max(Year))},Monthnum={"&amp;lt;=$(=max(MonthNum))"},Month=,Quater=&amp;gt;}[fieldname])&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;sum({&amp;lt;Year={$(max(Year))},MonthNum={"&amp;lt;=$(=Max(Monthnum))"},Month=,Quater=&amp;gt;}[cost per month])&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Rohit&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2014 05:36:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/YTD-Computation/m-p/589902#M218754</guid>
      <dc:creator>rohit214</dc:creator>
      <dc:date>2014-04-03T05:36:13Z</dc:date>
    </item>
  </channel>
</rss>

