<?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: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467064#M695165</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 really appreciate your efforts (I have to admit I lack knowledge about the Peek-function, I will study more about it to be sure) but this updated file doesn't really cut it either.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I modified the first data-loading-part to generate more data, to show you the problem:&lt;/P&gt;&lt;P&gt;Insert this code instead of the first INLINE statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;StuffOfInterest_initial:&lt;BR /&gt;LOAD Null() as YearMonth, Null() as ShelfID, Null() as Value AutoGenerate(1);&lt;/P&gt;&lt;P&gt;FOR YM = 201301 TO 201306 STEP 1&lt;BR /&gt; &lt;BR /&gt; FOR SID = 1 TO 10 STEP 1&lt;BR /&gt; &lt;BR /&gt;&amp;nbsp; FOR ValueCounter = 1 TO Round(Time(Today(1))/(Pow(Rand(),Rand())*1000)) STEP 1&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp;&amp;nbsp; CONCATENATE (StuffOfInterest_initial) LOAD&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(YM) as YearMonth,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(SID) as ShelfID,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Round(Rand()*(Today(1)/Rand())) as Value&lt;BR /&gt;&amp;nbsp;&amp;nbsp; AutoGenerate(1); &lt;BR /&gt;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; NEXT ValueCounter;&lt;BR /&gt; NEXT SID;&lt;BR /&gt;NEXT YM;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; If you look at the new result, Yearmonth 201301 we will get 10 H, 10 L and a lot of M.&lt;/P&gt;&lt;P&gt;So far, so good. The problem is that I want 100 H and 100 L and (the rest) M.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want EVERY ShelfID for EVERY YearMonth to have 10 H's and 10 L's (and M for the rest).&lt;BR /&gt;And if one shelf would have less then 10 values, then all should be H's.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Jun 2013 12:01:01 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2013-06-13T12:01:01Z</dc:date>
    <item>
      <title>How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467060#M695161</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everyone.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have this table:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;StuffOfInterest:&lt;/P&gt;&lt;P&gt;( YearMonth, ShelfID, Value)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After loading it in the script, I want to add a field called Priority to the table.&lt;/P&gt;&lt;P&gt;That field should just say 'H' (as in high) for the 10 entrys with highest value for each YearMonth and shelf.&lt;/P&gt;&lt;P&gt;How do I manage that? I have no problem in selecting the top 10 entrys for just YearMonth, but as I said:&lt;BR /&gt;I want this top-10 marking for YearMonth AND ShelfID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can someone in this community enlighten me?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then it would also be great if it could read 'L' (as in Low) for the 10 entrys with lowest value, and 'M' (as in Medium) for every other entry.&lt;/P&gt;&lt;P&gt;If that would be doable it would be even more great.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hoping for insight...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 14:53:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467060#M695161</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T14:53:54Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467061#M695162</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you mean this?&lt;/P&gt;&lt;P&gt;See attached&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 16:26:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467061#M695162</guid>
      <dc:creator />
      <dc:date>2013-06-12T16:26:48Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467062#M695163</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, and thanks for your imput.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can follow your thought, but your example doesn't really do the trick.&lt;/P&gt;&lt;P&gt;Maybe I was unable to express my problem. I will try to clarify.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I want is for the Indicator, for every YearMonth, and every shelfID, mark the entrys &lt;BR /&gt;with the top 10 vaues with a 'H'. The rest of the entrys may be marked with indicator=void(),&lt;BR /&gt;if that makes things easier. If the ShelfID has only 10 entrys or less, all entrys should be&lt;BR /&gt;marked with indicator='H'. In the example below i used top-5 instead of 10, just to show&lt;BR /&gt;the idea.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="292"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl63" height="17" width="67"&gt;YearMonth&lt;/TD&gt;&lt;TD class="xl63" style="border-left: medium none;" width="62"&gt;ShelfID&lt;/TD&gt;&lt;TD class="xl63" style="border-left: medium none;" width="73"&gt;Value&lt;/TD&gt;&lt;TD class="xl63" style="border-left: medium none;" width="90"&gt;Indicator&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;85&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;75&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;65&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;45&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;35&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;25&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;15&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;6&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;5&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;81&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;71&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;61&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;41&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;31&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;21&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;11&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;1&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;85&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;75&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;65&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;45&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;35&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;H&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;25&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;15&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;5&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl64" height="17" style="border-top: medium none;"&gt;201302&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;3&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;2&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none; border-top: medium none;"&gt;M&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the solution as easily can mark the bottom 10 entrys with a 'L' and all the entrys therebetween with 'M', that's a nice bonus, but what I really need is the top-10 marking in the field Indicator.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 17:51:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467062#M695163</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-12T17:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467063#M695164</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry, i got u wrong. Let's try again&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Jun 2013 19:36:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467063#M695164</guid>
      <dc:creator />
      <dc:date>2013-06-12T19:36:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467064#M695165</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 really appreciate your efforts (I have to admit I lack knowledge about the Peek-function, I will study more about it to be sure) but this updated file doesn't really cut it either.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I modified the first data-loading-part to generate more data, to show you the problem:&lt;/P&gt;&lt;P&gt;Insert this code instead of the first INLINE statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;StuffOfInterest_initial:&lt;BR /&gt;LOAD Null() as YearMonth, Null() as ShelfID, Null() as Value AutoGenerate(1);&lt;/P&gt;&lt;P&gt;FOR YM = 201301 TO 201306 STEP 1&lt;BR /&gt; &lt;BR /&gt; FOR SID = 1 TO 10 STEP 1&lt;BR /&gt; &lt;BR /&gt;&amp;nbsp; FOR ValueCounter = 1 TO Round(Time(Today(1))/(Pow(Rand(),Rand())*1000)) STEP 1&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp;&amp;nbsp; CONCATENATE (StuffOfInterest_initial) LOAD&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(YM) as YearMonth,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; $(SID) as ShelfID,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Round(Rand()*(Today(1)/Rand())) as Value&lt;BR /&gt;&amp;nbsp;&amp;nbsp; AutoGenerate(1); &lt;BR /&gt;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; NEXT ValueCounter;&lt;BR /&gt; NEXT SID;&lt;BR /&gt;NEXT YM;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; If you look at the new result, Yearmonth 201301 we will get 10 H, 10 L and a lot of M.&lt;/P&gt;&lt;P&gt;So far, so good. The problem is that I want 100 H and 100 L and (the rest) M.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want EVERY ShelfID for EVERY YearMonth to have 10 H's and 10 L's (and M for the rest).&lt;BR /&gt;And if one shelf would have less then 10 values, then all should be H's.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 12:01:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467064#M695165</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-13T12:01:01Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467065#M695166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am so sorry, I couldnt understand what your task was. But I hope I finally got it. Check this&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 15:34:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467065#M695166</guid>
      <dc:creator />
      <dc:date>2013-06-13T15:34:57Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467066#M695167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That was *exactly* what I meant. Wow. Great work, really! Many thanks, much appriciated! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 17:00:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467066#M695167</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-06-13T17:00:17Z</dc:date>
    </item>
    <item>
      <title>Re: How do I mark TOP/BOTTOM 10 entrys in a table with multiple dimensions</title>
      <link>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467067#M695168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Happy to hear that &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Jun 2013 17:16:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-do-I-mark-TOP-BOTTOM-10-entrys-in-a-table-with-multiple/m-p/467067#M695168</guid>
      <dc:creator />
      <dc:date>2013-06-13T17:16:20Z</dc:date>
    </item>
  </channel>
</rss>

