<?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: Sort Datetime in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815061#M1038924</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;please post sample app&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 05 Jan 2015 13:15:44 GMT</pubDate>
    <dc:creator>MarcoWedel</dc:creator>
    <dc:date>2015-01-05T13:15:44Z</dc:date>
    <item>
      <title>Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815052#M1038915</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;&lt;BR /&gt;Hello,&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;There is a date field, loaded in the format YYYYMMDDHHmmSS&lt;/DIV&gt;&lt;DIV&gt;I am using this field in a drilldown group as dimension to display month, week and day&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;Expressions used are &lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;=&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;month&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Mid&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[datefield]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;,1,8),'YYYYMMDD'))&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;=&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Week&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Mid&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[datefield]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;,1,8), 'YYYYMMDD')) &lt;/SPAN&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;= &lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Mid&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[datefield]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;,1,8), 'YYYYMMDD'),'MM/DD/YYYY') &lt;/SPAN&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;There is data from Oct 2014 to Jan 2015,&lt;/SPAN&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;currently I am sorting with numeric option, so it displays Jan first. (Jan, Oct, Nov, Dec)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;But actually I want to sort it in below order&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Oct&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Nov&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Dec&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Jan&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Please suggest how can I do this.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt; &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Thanks,&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 10pt;"&gt;Deepa&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 07:28:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815052#M1038915</guid>
      <dc:creator />
      <dc:date>2015-01-05T07:28:43Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815053#M1038916</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepa,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In sort inside expression do something like below as per ur required order.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Dual(Month,Match(Month,'jan','feb','mar','apr','may','jun','jul','aug','sep','oct','nov','dec')) &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;AS&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 07:32:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815053#M1038916</guid>
      <dc:creator>amit_saini</dc:creator>
      <dc:date>2015-01-05T07:32:23Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815054#M1038917</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Amit,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thx for the reply,&lt;/P&gt;&lt;P&gt;If I do that,what ever the year it sorts it in Jan,Feb,...Dec order.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I want it to consider the year ans month both in sorting&lt;/P&gt;&lt;P&gt;ex: if I select date range Oct2014 to Jan 2015&lt;/P&gt;&lt;P&gt;it shud be in the order Oct , Nov, Dec Jan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 07:36:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815054#M1038917</guid>
      <dc:creator />
      <dc:date>2015-01-05T07:36:03Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815055#M1038918</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;you should add in your load script an ID field for each datefield (maybe with &lt;STRONG&gt;autonumber()&lt;/STRONG&gt; instruction that "labels" every value of datefield with a progressive number).&lt;/P&gt;&lt;P&gt;Then you can insert the ID field in the expression of sort tab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Elena&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 10:24:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815055#M1038918</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-05T10:24:08Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815056#M1038919</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepa, you can sort your months using an expression like Min({1} datefield)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 10:31:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815056#M1038919</guid>
      <dc:creator>rubenmarin</dc:creator>
      <dc:date>2015-01-05T10:31:26Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815057#M1038920</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use this expression in sort tab&lt;/P&gt;&lt;P&gt;date#(Mid([&lt;SPAN style="color: #800000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 11px;"&gt;datefield&lt;/SPAN&gt;],1,8), 'YYYYMMDD')&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 10:34:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815057#M1038920</guid>
      <dc:creator>anbu1984</dc:creator>
      <dc:date>2015-01-05T10:34:54Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815058#M1038921</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;in the Script generate a numeric value for your date column and the use that column for the sorting. &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10.3999996185303px;"&gt;num(datefield) as SortDate&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10.3999996185303px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #800000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10.3999996185303px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 10:35:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815058#M1038921</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-01-05T10:35:39Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815059#M1038922</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepa,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can define your sort order exactly with a inine table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LoadorderMonths:&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Months&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; OCT&lt;/P&gt;&lt;P&gt;&amp;nbsp; NOV&lt;/P&gt;&lt;P&gt;&amp;nbsp; DEC&lt;/P&gt;&lt;P&gt;&amp;nbsp; JAN&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;Bumin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 10:36:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815059#M1038922</guid>
      <dc:creator>bumin</dc:creator>
      <dc:date>2015-01-05T10:36:45Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815060#M1038923</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepa,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;While loading, sort the date field (in script using order by) then sort month by Loaded Order.&lt;/P&gt;&lt;P&gt;&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;Harsha&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 11:46:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815060#M1038923</guid>
      <dc:creator />
      <dc:date>2015-01-05T11:46:37Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815061#M1038924</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;please post sample app&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 13:15:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815061#M1038924</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2015-01-05T13:15:44Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815062#M1038925</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can use to sort by month:&lt;/P&gt;&lt;P&gt;Num(Month(&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #0000ff;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #0000ff;"&gt;Mid&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #800000;"&gt;[datefield]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;,1,8),'YYYYMMDD')), '00')&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 13:33:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815062#M1038925</guid>
      <dc:creator>ecolomer</dc:creator>
      <dc:date>2015-01-05T13:33:35Z</dc:date>
    </item>
    <item>
      <title>Re: Sort Datetime</title>
      <link>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815063#M1038926</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepa,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please find the attached file.&lt;/P&gt;&lt;P&gt;Hope it will help to you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Jan 2015 13:46:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sort-Datetime/m-p/815063#M1038926</guid>
      <dc:creator>v_iyyappan</dc:creator>
      <dc:date>2015-01-05T13:46:47Z</dc:date>
    </item>
  </channel>
</rss>

