<?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 Sorting Macro in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363364#M135125</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; the type of sheet object is straight table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 23 Apr 2012 11:32:42 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-04-23T11:32:42Z</dc:date>
    <item>
      <title>Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363362#M135123</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I have to sort a table by dimension where all the selected values should come on top. What will be the macro for that ??&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 09:53:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363362#M135123</guid>
      <dc:creator />
      <dc:date>2012-04-23T09:53:38Z</dc:date>
    </item>
    <item>
      <title>Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363363#M135124</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;&lt;/P&gt;&lt;P&gt;What is the type of sheet object you want this to achieve/&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Darius&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 11:04:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363363#M135124</guid>
      <dc:creator>d_pranskus</dc:creator>
      <dc:date>2012-04-23T11:04:49Z</dc:date>
    </item>
    <item>
      <title>Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363364#M135125</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; the type of sheet object is straight table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 11:32:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363364#M135125</guid>
      <dc:creator />
      <dc:date>2012-04-23T11:32:42Z</dc:date>
    </item>
    <item>
      <title>Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363365#M135126</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;It is better to use list box for that. In QV11 it allows expressions. In this case you will have a posibility to sort selected values at the top and excluded at the bottom.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;Darius&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 11:48:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363365#M135126</guid>
      <dc:creator>d_pranskus</dc:creator>
      <dc:date>2012-04-23T11:48:12Z</dc:date>
    </item>
    <item>
      <title>Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363366#M135127</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I can not do that. My requirement is such that i have to display the volumes of different products in one table and if i select multiple products. the selected products should be highlighted and the remaining products should also be listed there. But all the selected products should be at the top of the table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 11:52:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363366#M135127</guid>
      <dc:creator />
      <dc:date>2012-04-23T11:52:47Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363367#M135128</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;Try this example as starting point&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers&lt;/P&gt;&lt;P&gt;Darius&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 12:34:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363367#M135128</guid>
      <dc:creator>d_pranskus</dc:creator>
      <dc:date>2012-04-23T12:34:12Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363368#M135129</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;That's not the way Qlikview normally works. Normally, list boxes will display all values, and (depending on the sort criteria) put the selected items on top. Straight tables will only display selected items, non-selected items, or items excluded by selections on other fields will not display at all.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are some tricks to override the bahaviour in list boxes, but you cannot change the selection behaviour in straight tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What you can do is create an island field (eg ProductIsland in DataIsland table) for the products you want to highight. Display this in a list box so you can make select products to highlight.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Define a variable vTest:&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;=chr(39) &amp;amp; GetFieldSelections(ProductIsland, chr(39) &amp;amp; ',' &amp;amp; chr(39), 10) &amp;amp; chr(39)&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;(where 10 is the maximum number of selections to allow)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Click the + sign next to the expression to highlight, and select foreground or background colour:&lt;/LI&gt;&lt;/UL&gt;&lt;P style="padding-left: 30px;"&gt;Enter an expression something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; eg for background:&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If(Dimensionality()&amp;gt;0 And Match(Product, $(vTest)) &amp;lt;&amp;gt; 0, Yellow())&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;And in the sort, enter an expression like (to sort by product), or enter a hidden column and sort by that column (before hiding it). Also disable interactive sorting:&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;﻿&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If(Match(Product, $(vTest)), 'z', 'a') &amp;amp; Product&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the attached.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Jonathan&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit: Darius' example is better than mine, I think &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/shocked.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 13:17:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363368#M135129</guid>
      <dc:creator>jonathandienst</dc:creator>
      <dc:date>2012-04-23T13:17:17Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting Macro</title>
      <link>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363369#M135130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; You can do it without macro.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Use Sort by Expression in the sort Tab of the chart properties.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; =if(Match(FieldName,$(=chr(39)&amp;amp;GetFieldSelections(FieldName,chr(39)&amp;amp;','&amp;amp;chr(39),&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;20&lt;/STRONG&gt;&lt;/SPAN&gt;)&amp;amp;chr(39))),0,1)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Instead of 20 you can use maximum number of field values.&lt;/P&gt;&lt;P&gt;Celambarasan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Apr 2012 13:28:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sorting-Macro/m-p/363369#M135130</guid>
      <dc:creator>CELAMBARASAN</dc:creator>
      <dc:date>2012-04-23T13:28:08Z</dc:date>
    </item>
  </channel>
</rss>

