<?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: Problem while implementing rank in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319087#M586580</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;&amp;nbsp;&amp;nbsp; Have a look at the attached document.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Is these what you want..?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kaushik Solanki&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 30 Jul 2011 08:27:34 GMT</pubDate>
    <dc:creator>kaushiknsolanki</dc:creator>
    <dc:date>2011-07-30T08:27:34Z</dc:date>
    <item>
      <title>Problem while implementing rank</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319086#M586579</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have a requirement where a client needs to be ranked against different peer groups (type/tier)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have attached an example do demonstrate the problem.. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once a client (CMU) is selected, user should be able to pick any different Type &amp;amp; Tier and the selected client should be ranked against clients falling under the selected Type and Tier.. I tried to use Qualify and designed below expression, but that does not seem to work properly...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;RANK(sum({&amp;lt;TYPE=QUAL_CLIENTS.TYPE,TIER=QUAL_CLIENTS.TIER&amp;gt;}REVENUE),1,1) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;business wants to find out how a client was performing in each month against the other set of clients...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Can someone please help in building the above expression.. also please provide if you have better solution where we dont need to use Qualify&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;thanks in advance!!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;EDIT - Please refer to Test.qvw from 3rd post.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 29 Jul 2011 18:49:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319086#M586579</guid>
      <dc:creator />
      <dc:date>2011-07-29T18:49:08Z</dc:date>
    </item>
    <item>
      <title>Re: Problem while implementing rank</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319087#M586580</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;&amp;nbsp;&amp;nbsp; Have a look at the attached document.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Is these what you want..?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kaushik Solanki&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 30 Jul 2011 08:27:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319087#M586580</guid>
      <dc:creator>kaushiknsolanki</dc:creator>
      <dc:date>2011-07-30T08:27:34Z</dc:date>
    </item>
    <item>
      <title>Re: Problem while implementing rank</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319088#M586581</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Kaushik.. &lt;/P&gt;&lt;P&gt;I am not looking for straightforward ranking.. this is a little different requirement...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Attached file shows an example and the details as to what type of ranking I am looking for...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I have to write a program, this is what I'd do -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- for selected tier and type, find all associated clients&lt;/P&gt;&lt;P&gt;- among those clients, rank the selected client in terms of revenune for each month.. even though the selected client does not fall under selected tier and type..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It seems challenging defining this logic using QlikView...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 31 Jul 2011 16:31:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319088#M586581</guid>
      <dc:creator />
      <dc:date>2011-07-31T16:31:19Z</dc:date>
    </item>
    <item>
      <title>Re: Problem while implementing rank</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319089#M586582</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So if I select GOLD and BANKS, the CMUs are AMUNDI, BRANDYWINE and TEMPLETON GLOBAL.&amp;nbsp; You want to rank the selected CMU, SLS CAP, against these three other CMUs on total revenue regardless of type and tier.&amp;nbsp; In this case, it should rank 3 in January and 2 in February and March.&amp;nbsp; But you want to do that &lt;EM&gt;without&lt;/EM&gt; having to select AMUNDI, BRANDYWINE, SLS CAP and TEMPLETON GLOBAL, and &lt;EM&gt;without&lt;/EM&gt; deselecting TYPE and TIER.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If so, then you almost had it.&amp;nbsp; I believe you only need to add a single character to your expression, a + sign to indicate a union.&amp;nbsp; This produces the right results for the example, and I believe matches the above definition:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;if(CLIENT_VAR=CMU,rank(sum({$&lt;SPAN style="color: #ff0000; font-size: 14pt;"&gt;&lt;STRONG&gt;+&lt;/STRONG&gt;&lt;/SPAN&gt;&amp;lt;CMU=,TYPE=QUAL_CLIENTS.TYPE,TIER=QUAL_CLIENTS.TIER&amp;gt;} REVENUE)))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Aug 2011 19:18:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319089#M586582</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-08-01T19:18:29Z</dc:date>
    </item>
    <item>
      <title>Re: Problem while implementing rank</title>
      <link>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319090#M586583</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;Trying a slight variation on that solution, to try and remove the 'qualified by' table bit, ended up with an expression like this....(amended doc attached)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(CLIENT_VAR=maxstring( {$+1&amp;lt;CMU={'$(CLIENT_VAR)'}&amp;gt;} CMU) , &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;rank( sum({$+1&amp;lt;CMU={'$(CLIENT_VAR)'}&amp;gt;} REVENUE )))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;which seemed to work with just selecting from a Client list (which could be made into a single field data island) - other Tier and Type selections could be done on the normal table fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I'm not sure if there isn't a simpler way of doing the 'If (CLIENT_VAR = CMU..' condition as I've had to add a 'maxstring' to pick out distinct values for the condition to work.&amp;nbsp; Are there other alternatives ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HD &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Aug 2011 17:04:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Problem-while-implementing-rank/m-p/319090#M586583</guid>
      <dc:creator>hdonald</dc:creator>
      <dc:date>2011-08-02T17:04:33Z</dc:date>
    </item>
  </channel>
</rss>

