<?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 Calculating Difference in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844041#M998767</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts&lt;/P&gt;&lt;P&gt;I am using a Straight table and calculating the difference in Sales&lt;/P&gt;&lt;P&gt;Formula is&amp;nbsp; &lt;STRONG&gt;&amp;nbsp; Difference = [Last Month Sales] - [Current Month Sales]&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Difference is sorted in Ascending order, at the top negative values and below are positive values&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now in that Chart I want to show only top 20 Negative values&lt;/P&gt;&lt;P&gt;How Shall I do this by using set analysis&lt;/P&gt;&lt;P&gt;Please Suggest&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 17 Jun 2015 13:23:32 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-06-17T13:23:32Z</dc:date>
    <item>
      <title>Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844041#M998767</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts&lt;/P&gt;&lt;P&gt;I am using a Straight table and calculating the difference in Sales&lt;/P&gt;&lt;P&gt;Formula is&amp;nbsp; &lt;STRONG&gt;&amp;nbsp; Difference = [Last Month Sales] - [Current Month Sales]&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Difference is sorted in Ascending order, at the top negative values and below are positive values&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now in that Chart I want to show only top 20 Negative values&lt;/P&gt;&lt;P&gt;How Shall I do this by using set analysis&lt;/P&gt;&lt;P&gt;Please Suggest&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 13:23:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844041#M998767</guid>
      <dc:creator />
      <dc:date>2015-06-17T13:23:32Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844042#M998768</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the dimension limits tab to restrict it to show only smallest 20 values. Have you given that a shot?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 13:27:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844042#M998768</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-17T13:27:17Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844043#M998769</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI&lt;/P&gt;&lt;P&gt;MY dimensions are Branch &amp;amp; customer&lt;/P&gt;&lt;P&gt;When I Restrict Customer by First 20 positive values are also coming&lt;/P&gt;&lt;P&gt;Please Suggest&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 13:34:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844043#M998769</guid>
      <dc:creator />
      <dc:date>2015-06-17T13:34:00Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844044#M998770</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You might be able to use rank function to get the results you are looking for... but you will need to share some information related to your expression... Having a sample application would be ideal.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 13:41:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844044#M998770</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-17T13:41:04Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844045#M998771</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;Please check the screenshot. Select the field in Presentation Tab and change the Max Number to 20.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;Thanks,&lt;/P&gt;&lt;P style="font-size: 13.3333330154419px;"&gt;Muru&lt;/P&gt;&lt;P&gt;&lt;IMG alt="First20NegativeValues.JPG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/89774_First20NegativeValues.JPG" style="height: 541px; width: 620px;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:08:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844045#M998771</guid>
      <dc:creator />
      <dc:date>2015-06-17T14:08:01Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844046#M998772</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI&lt;/P&gt;&lt;P&gt;Here with this I attached the Sample&lt;/P&gt;&lt;P&gt;but in the sample its working correctly but not in my actual QVW&lt;/P&gt;&lt;P&gt;my Actual QVW Screen shot is attached&lt;/P&gt;&lt;P&gt;Please Suggest&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.JPG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/89777_Capture.JPG" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:23:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844046#M998772</guid>
      <dc:creator />
      <dc:date>2015-06-17T14:23:16Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844047#M998773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Murugesh&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried this way but not able to bring the total for those 20 &lt;/P&gt;&lt;P&gt;it is generating overall total&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:24:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844047#M998773</guid>
      <dc:creator />
      <dc:date>2015-06-17T14:24:48Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844048#M998774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Does this looks like what you want??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/89780_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Used the following calculated dimension:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;=If(Aggr(Rank(-(Sum([Last Month SPD]) - Sum([Current Month SPD]))), [Customer Account Number]) &amp;lt;=20, [Customer Account Number])&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and suppressed the Null (on the dimension tab)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also attaching the sample app for reference.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:33:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844048#M998774</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-17T14:33:58Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844049#M998775</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Sunny&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;The Screen shot is exactly what I am Looking for&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;but the Lost Month SPD and Current Month SPD are Calculated in that same table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;my Actual Data looks like the attached Xls&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My Formula for calculating&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;&lt;STRONG&gt;Lost Month SPD&lt;/STRONG&gt; = &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Sum({&amp;lt; [DEC_MonthYear] =, DEC_Date = {'&amp;gt;=$(=Date(MONTHSTART(AddMonths(vMaxSalesDate, -1))))&amp;lt;=$(=Date(MONTHEND(AddMonths(vMaxSalesDate, -1))))'} &amp;gt;} Sales) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt; and &lt;STRONG&gt;Current Month SPD = &lt;/STRONG&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt; Sum({&amp;lt; DEC_MonthYear=, DEC_Date = {'&amp;gt;=$(=Date(MonthStart(vMaxSalesDate)))&amp;lt;=$(=Date(vMaxSalesDate))'} &amp;gt;} Sales)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px;"&gt;Please Suggest&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:53:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844049#M998775</guid>
      <dc:creator />
      <dc:date>2015-06-17T14:53:44Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844050#M998776</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you see if this works:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=If(Aggr(Rank(-((&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;Sum({&amp;lt; [DEC_MonthYear] =, DEC_Date = {'&amp;gt;=$(=Date(MONTHSTART(AddMonths(vMaxSalesDate, -1))))&amp;lt;=$(=Date(MONTHEND(AddMonths(vMaxSalesDate, -1))))'} &amp;gt;} Sales))&lt;/SPAN&gt; - (&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13.3333330154419px;"&gt;Sum({&amp;lt; DEC_MonthYear=, DEC_Date = {'&amp;gt;=$(=Date(MonthStart(vMaxSalesDate)))&amp;lt;=$(=Date(vMaxSalesDate))'} &amp;gt;} Sales))&lt;/SPAN&gt;)),&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;[Customer Account Number]) &amp;lt;=20, [Customer Account Number])&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I am not sure if I got all the parenthesis right so make sure those are in order&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 14:58:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844050#M998776</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-17T14:58:27Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844051#M998777</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Sunny&lt;/P&gt;&lt;P&gt;Unfortunately its not Working, its not bringing up any Values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Actually I am Using this expression in the dimension tab to bring up top 200 customer by sales is there&lt;/P&gt;&lt;P&gt;a way to do this around like Ranking in the script itself or using sum, max (sales)&lt;/P&gt;&lt;P&gt;Please Suggest&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 15:16:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844051#M998777</guid>
      <dc:creator />
      <dc:date>2015-06-17T15:16:58Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844052#M998778</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am getting a little confused, can you help me understand what your requirement is? and can you also give a representative data where I can implement it which would help you implement in your final version.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 16:55:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844052#M998778</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-06-17T16:55:33Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating Difference</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844053#M998779</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Sunny&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here Is the Actual Data for one Branch, but I got 152 branches&lt;/P&gt;&lt;P&gt;I want to choose top 200 customers by Sales for each branch for my analysis&lt;/P&gt;&lt;P&gt;for that I am using this expression &lt;STRONG&gt;=aggr(if(rank(sum(SALES))&amp;lt;=200,CUSTOMER),BRANCH,CUSTOMER)&lt;/STRONG&gt;&lt;STRONG style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;IN Dimensions instead of CUSTOMER to bring top 200 customers by sales for each branch &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;in expression I am calculating the Last Month SPD ,Current Month SPD and Difference &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;now my table will show 200 values but I want to show only top 20 lines in the table&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2015 17:09:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-Difference/m-p/844053#M998779</guid>
      <dc:creator />
      <dc:date>2015-06-17T17:09:32Z</dc:date>
    </item>
  </channel>
</rss>

