<?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: FirstSortedValue or set analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412392#M487967</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm sorry but this does not work&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Feb 2013 17:13:01 GMT</pubDate>
    <dc:creator>paolojolly</dc:creator>
    <dc:date>2013-02-07T17:13:01Z</dc:date>
    <item>
      <title>FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412388#M487963</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, &lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;I have this table &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;&lt;IMG __jive_id="33213" class="jive-image" alt="Immagine2.bmp" src="https://community.qlik.com/legacyfs/online/33213_Immagine2.bmp" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;I need to create a pivot table with ProductType as dimension and in expression the value of status for the max(Date) of &lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;ProductType&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;I try to use &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;max({&amp;lt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Date&lt;/SPAN&gt;={"$(=max(&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Date&lt;/SPAN&gt;))"}&amp;gt;} &lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Status&lt;/SPAN&gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;but the result is not correct. So I try to use &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;FirstSortedValue(distinct Status, -Date)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;But I'm not sure that it is the best solution.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;Help me on this...urgent&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;Thank you&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; background-color: #ffffff; font-family: Arial;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 08:09:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412388#M487963</guid>
      <dc:creator>paolojolly</dc:creator>
      <dc:date>2013-02-07T08:09:44Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412389#M487964</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;use below in your Expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Only({&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;Date&lt;/SPAN&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;={"$(=max(&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;Date&lt;/SPAN&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;))"}&amp;gt;} &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;Status&lt;/SPAN&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;hope this helps&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 08:40:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412389#M487964</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2013-02-07T08:40:11Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412390#M487965</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hiii&lt;/P&gt;&lt;P&gt;try this in script level&lt;/P&gt;&lt;P&gt;LOAD producttype,&lt;/P&gt;&lt;P&gt;ID,&lt;/P&gt;&lt;P&gt;max(Date)as maxDate,&lt;/P&gt;&lt;P&gt;FirstSortedValue(Status,-Date)as Status&amp;nbsp; &lt;/P&gt;&lt;P&gt;group by producttype;&lt;/P&gt;&lt;P&gt;load ur table fields&lt;/P&gt;&lt;P&gt;from ......;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 08:54:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412390#M487965</guid>
      <dc:creator>er_mohit</dc:creator>
      <dc:date>2013-02-07T08:54:44Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412391#M487966</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;STRONG&gt;try this&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD producttype,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;date(max(date))as maxDate,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FirstSortedValue(status,-date)as Status &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;group by producttype;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD auditnmame, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; date, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; id, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; producttype, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; status&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;C:\Users\vishwaranjan\Desktop\FIRSTSORTED.xlsx&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(ooxml, embedded labels, table is Sheet1);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;then output like this&lt;/STRONG&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="294"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl63" height="17" width="98"&gt;producttype&lt;/TD&gt;&lt;TD class="xl64" width="98"&gt;maxDate&lt;/TD&gt;&lt;TD class="xl64" style="border-left: medium none;" width="98"&gt;Status&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl65" height="17" style="border-top: medium none;"&gt;AA&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-top: medium none; border-left: medium none;"&gt;2/1/2013&lt;/TD&gt;&lt;TD class="xl64" style="border-top: medium none; border-left: medium none;"&gt;BADX&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl65" height="17" style="border-top: medium none;"&gt;BB&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-top: medium none; border-left: medium none;"&gt;1/2/2012&lt;/TD&gt;&lt;TD class="xl64" style="border-top: medium none; border-left: medium none;"&gt;GOOD&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl65" height="17" style="border-top: medium none;"&gt;CC&lt;/TD&gt;&lt;TD align="right" class="xl66" style="border-top: medium none; border-left: medium none;"&gt;5/1/2013&lt;/TD&gt;&lt;TD class="xl64" style="border-top: medium none; border-left: medium none;"&gt;GOOD&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 09:20:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412391#M487966</guid>
      <dc:creator />
      <dc:date>2013-02-07T09:20:48Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412392#M487967</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm sorry but this does not work&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 17:13:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412392#M487967</guid>
      <dc:creator>paolojolly</dc:creator>
      <dc:date>2013-02-07T17:13:01Z</dc:date>
    </item>
    <item>
      <title>Re: FirstSortedValue or set analysis</title>
      <link>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412393#M487968</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, This solution help me, but now I have another problem. I have changed the table in &lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="33238" class="jive-image" alt="Immagine3.bmp" src="https://community.qlik.com/legacyfs/online/33238_Immagine3.bmp" /&gt;&lt;/P&gt;&lt;P&gt;and I &lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;need to create a pivot table with ProductType as dimension and in expression the value of status for the max(Date) of &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; color: #737373; font-family: Arial;"&gt;ProductType and I need to use a list box for filter the information on SalesRep and another for Customer. For example If i select in Customer list box "Cust1" the pivot shoud give me for each ProductType the values of Status field for the max(Date), idem if I work with &lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;SalesRep&lt;/SPAN&gt; listbox&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;Thanks&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #737373; font-family: Arial; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Feb 2013 18:42:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FirstSortedValue-or-set-analysis/m-p/412393#M487968</guid>
      <dc:creator>paolojolly</dc:creator>
      <dc:date>2013-02-07T18:42:06Z</dc:date>
    </item>
  </channel>
</rss>

