<?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: RE : SORT ORDER in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722358#M259320</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Or you need something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;load *,SubField(Test,',') as Test1,&lt;/P&gt;&lt;P&gt;SubField(Test,',',1) as Test2,&lt;/P&gt;&lt;P&gt;SubField(Test,',',2) as Test3,&lt;/P&gt;&lt;P&gt;SubField(Test,',',3) as Test4;&lt;/P&gt;&lt;P&gt;load * Inline&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;Test&lt;/P&gt;&lt;P&gt;"20130812,20121001,20121003"&lt;/P&gt;&lt;P&gt;"20130812,20121001,20121003"&lt;/P&gt;&lt;P&gt;]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;ASHFAQ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 21 Aug 2014 13:02:33 GMT</pubDate>
    <dc:creator>ashfaq_haseeb</dc:creator>
    <dc:date>2014-08-21T13:02:33Z</dc:date>
    <item>
      <title>RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722351#M259313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a field which is a combination of dates(ie..20130812,20121001,20121003). the requirement is i need to make separate fields from this field in the descending order of dates.&lt;/P&gt;&lt;P&gt;EG.&lt;/P&gt;&lt;P&gt;.field-1 as 20130812&lt;/P&gt;&lt;P&gt;filed-2 as 20121003&lt;/P&gt;&lt;P&gt;filed-3 as 20121001&lt;/P&gt;&lt;P&gt;like this...&lt;/P&gt;&lt;P&gt;how can it be achieved??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please suggest..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks in advance../&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:38:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722351#M259313</guid>
      <dc:creator />
      <dc:date>2014-08-21T12:38:02Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722352#M259314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can you explain more, please&lt;/P&gt;&lt;P&gt;the fields are in a record?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:40:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722352#M259314</guid>
      <dc:creator>ecolomer</dc:creator>
      <dc:date>2014-08-21T12:40:50Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722353#M259315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Separate fields in year, month and day?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;left(field, 4) as year,&lt;/P&gt;&lt;P&gt;mid(field, 5,2) as month,&lt;/P&gt;&lt;P&gt;rigth(field, 2) as day&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:42:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722353#M259315</guid>
      <dc:creator>ecolomer</dc:creator>
      <dc:date>2014-08-21T12:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722354#M259316</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,,&lt;/P&gt;&lt;P&gt;try below&lt;/P&gt;&lt;P&gt;load *,SubField(Test,',') as Test1;&lt;/P&gt;&lt;P&gt;load * Inline&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;Test&lt;/P&gt;&lt;P&gt;"20130812,20121001,20121003"&lt;/P&gt;&lt;P&gt;]&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;ASHFAQ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:45:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722354#M259316</guid>
      <dc:creator>ashfaq_haseeb</dc:creator>
      <dc:date>2014-08-21T12:45:59Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722355#M259317</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 like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think your date is in text format..&lt;/P&gt;&lt;P&gt;Date(Date#(DateField, 'YYYYMMDD')) AS Date&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After that display as in descending order by using Sorting tab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit:&lt;/P&gt;&lt;P&gt;If you need to separate the field values ., try with SubField() functions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ex:&lt;/P&gt;&lt;P&gt;SubField(DateField,',')&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:47:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722355#M259317</guid>
      <dc:creator>MayilVahanan</dc:creator>
      <dc:date>2014-08-21T12:47:10Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722356#M259318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi..&lt;/P&gt;&lt;P&gt;The Main field contains the values like &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;ie..20130812,20121001,20121003 (This is 1 value of the filed like this there are 'n' no of records) these are all dates in YYYYMMDD format.it doesn't have any order as ascending or descending.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Requirement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;need to make 3 Sub fields according to the descending order of dates&lt;/P&gt;&lt;P&gt;here for this value it will be&lt;/P&gt;&lt;P&gt;Subfield 1 : &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;20130812&lt;/SPAN&gt; (max date)&lt;/P&gt;&lt;P&gt;Subfield 2 : &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;20121003&lt;/SPAN&gt;(max-1 date)&lt;/P&gt;&lt;P&gt;Subfield&amp;nbsp; 3 : &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;20121001&lt;/SPAN&gt; (Max-2 date)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:55:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722356#M259318</guid>
      <dc:creator />
      <dc:date>2014-08-21T12:55:14Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722357#M259319</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;did you try my suggestion.&lt;/P&gt;&lt;P&gt;Can you post sample data with 5-10 records with expected output.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;ASHFAQ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 12:59:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722357#M259319</guid>
      <dc:creator>ashfaq_haseeb</dc:creator>
      <dc:date>2014-08-21T12:59:11Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722358#M259320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Or you need something like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;load *,SubField(Test,',') as Test1,&lt;/P&gt;&lt;P&gt;SubField(Test,',',1) as Test2,&lt;/P&gt;&lt;P&gt;SubField(Test,',',2) as Test3,&lt;/P&gt;&lt;P&gt;SubField(Test,',',3) as Test4;&lt;/P&gt;&lt;P&gt;load * Inline&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;Test&lt;/P&gt;&lt;P&gt;"20130812,20121001,20121003"&lt;/P&gt;&lt;P&gt;"20130812,20121001,20121003"&lt;/P&gt;&lt;P&gt;]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;ASHFAQ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 13:02:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722358#M259320</guid>
      <dc:creator>ashfaq_haseeb</dc:creator>
      <dc:date>2014-08-21T13:02:33Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722359#M259321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi..&lt;/P&gt;&lt;P&gt;Thanks for the reply..&lt;/P&gt;&lt;P&gt;as you said we can separate the fields using subfield and date functions can be applied.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But i need to make the subfield according to the descending order of dates.&lt;/P&gt;&lt;P&gt;How it will be possible??&lt;/P&gt;&lt;P&gt;pls suggest...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Reena&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 13:04:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722359#M259321</guid>
      <dc:creator />
      <dc:date>2014-08-21T13:04:18Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722360#M259322</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 think, need to use macro in script to rearrange the dates before use the subfield function.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 13:12:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722360#M259322</guid>
      <dc:creator>MayilVahanan</dc:creator>
      <dc:date>2014-08-21T13:12:50Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722361#M259323</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Reena,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this works for 3 date values:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD *, &lt;/P&gt;&lt;P&gt;NumMax(Date1,Date2,Date3) as DateSorted1,&lt;/P&gt;&lt;P&gt;(Date1 + Date2 + Date3 - NumMax(Date1,Date2,Date3) - NumMin(Date1,Date2,Date3)) as DateSorted2,&lt;/P&gt;&lt;P&gt;NumMin(Date1,Date2,Date3) as DateSorted3;&lt;/P&gt;&lt;P&gt;LOAD RawData,&lt;/P&gt;&lt;P&gt;SubField(RawData,',',1) as Date1,&lt;/P&gt;&lt;P&gt;SubField(RawData,',',2) as Date2,&lt;/P&gt;&lt;P&gt;SubField(RawData,',',3) as Date3&lt;/P&gt;&lt;P&gt;Inline &lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;RawData&lt;/P&gt;&lt;P&gt;"20130927,20121010,20140311"&lt;/P&gt;&lt;P&gt;"20140502,20140821,20131230"&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Ralf&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 21 Aug 2014 13:30:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722361#M259323</guid>
      <dc:creator>rbecher</dc:creator>
      <dc:date>2014-08-21T13:30:38Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722362#M259324</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;Thanks for the reply,...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i hope ,in case if i have more no of dates in the field then i cant use this method ?? &lt;/P&gt;&lt;P&gt;But in my case,it may not be exactly 3 dates,it can be more or can vary.. .:(&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Aug 2014 04:23:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722362#M259324</guid>
      <dc:creator />
      <dc:date>2014-08-22T04:23:59Z</dc:date>
    </item>
    <item>
      <title>Re: RE : SORT ORDER</title>
      <link>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722363#M259325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No this works only for 3 data values in a field. If you have mutable amount of date values in the field you can use an aggregation to get out the sorted first 3 values:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD ID, &lt;/P&gt;&lt;P&gt;FirstSortedValue(Date,-Date,1) as Date1,&lt;/P&gt;&lt;P&gt;FirstSortedValue(Date,-Date,2) as Date2,&lt;/P&gt;&lt;P&gt;FirstSortedValue(Date,-Date,3) as Date3&lt;/P&gt;&lt;P&gt;Group By ID;&lt;/P&gt;&lt;P&gt;LOAD ID,&lt;/P&gt;&lt;P&gt;SubField(RawData,',') as Date&lt;/P&gt;&lt;P&gt;Inline&lt;/P&gt;&lt;P&gt;[&lt;/P&gt;&lt;P&gt;ID,RawData&lt;/P&gt;&lt;P&gt;1,"20130927,20121010,20140311"&lt;/P&gt;&lt;P&gt;2,"20140502,20140821,20131230,20140109"&lt;/P&gt;&lt;P&gt;3,"20130717,20121112,20140209,20130903,20140423"&lt;/P&gt;&lt;P&gt;4,"20130301,20140601,20131230"&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- Ralf&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Aug 2014 07:50:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/RE-SORT-ORDER/m-p/722363#M259325</guid>
      <dc:creator>rbecher</dc:creator>
      <dc:date>2014-08-22T07:50:14Z</dc:date>
    </item>
  </channel>
</rss>

