<?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: Sorting order by expression for today() function in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128824#M9030</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ow and if you want that to be "dynamic" per reload day, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;let FirstWeekDay= weekday(today());&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 14 Sep 2018 18:54:19 GMT</pubDate>
    <dc:creator>mikaelsc</dc:creator>
    <dc:date>2018-09-14T18:54:19Z</dc:date>
    <item>
      <title>Sorting order by expression for today() function</title>
      <link>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128822#M9028</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I am looking for a different way to order weekdays. I want the weekday of today to be the first in a barchart. Today is a friday for example, so I want the figure to display: fri - sat - sun - mon - tue - wed - thu.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is what I am currently trying, but it gives a wrong, random order: &lt;/P&gt;&lt;P&gt;=IF(weekday([datefield])=weekday(today()),1,&lt;/P&gt;&lt;P&gt; IF(weekday(&lt;SPAN style="font-size: 13.3333px;"&gt;[datefield]&lt;/SPAN&gt;)=weekday(today()+1),2,&lt;/P&gt;&lt;P&gt;&amp;nbsp; IF(weekday(&lt;SPAN style="font-size: 13.3333px;"&gt;[datefield]&lt;/SPAN&gt;)=WeekDay(today()+2),3,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; IF(weekday(&lt;SPAN style="font-size: 13.3333px;"&gt;[datefield])&lt;/SPAN&gt;=weekday(today()+3),4,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; IF(weekday(&lt;SPAN style="font-size: 13.3333px;"&gt;[datefield]&lt;/SPAN&gt;)=weekday(today()+4),5,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IF(weekday(&lt;SPAN style="font-size: 13.3333px;"&gt;[datefield]&lt;/SPAN&gt;)=weekday(today()+5),6,7))))))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm looking forward to seeing your solutions! Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 16 Nov 2024 07:39:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128822#M9028</guid>
      <dc:creator>bartdeboed</dc:creator>
      <dc:date>2024-11-16T07:39:16Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting order by expression for today() function</title>
      <link>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128823#M9029</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Bart, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the most simple/clean would be, i guess, to change this variable in the load script:&amp;nbsp; (this of course means it will be applied everywhere in your app) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SET FirstWeekDay=0;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;change that to: SET FirstWeekDay=4; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/NumberInterpretationVariables/FirstWeekDay.htm" title="https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/NumberInterpretationVariables/FirstWeekDay.htm"&gt;https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/NumberInterpretationVariables/FirstWeekDay.h…&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so when sorting your days, you'll get fridays first: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/DateAndTimeFunctions/weekday.htm" title="https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/DateAndTimeFunctions/weekday.htm"&gt;https://help.qlik.com/en-US/sense/June2018/Subsystems/Hub/Content/Scripting/DateAndTimeFunctions/weekday.htm&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Sep 2018 18:52:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128823#M9029</guid>
      <dc:creator>mikaelsc</dc:creator>
      <dc:date>2018-09-14T18:52:38Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting order by expression for today() function</title>
      <link>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128824#M9030</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ow and if you want that to be "dynamic" per reload day, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12px; background-color: #f2f2f2;"&gt;let FirstWeekDay= weekday(today());&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Sep 2018 18:54:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128824#M9030</guid>
      <dc:creator>mikaelsc</dc:creator>
      <dc:date>2018-09-14T18:54:19Z</dc:date>
    </item>
    <item>
      <title>Re: Sorting order by expression for today() function</title>
      <link>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128825#M9031</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can add Week Sort Order column in your table where you will specify incremental number for each weekday and add&amp;nbsp; that sort order using new derived column &lt;SPAN style="font-size: 10pt;"&gt;in chart properties as required. Sorting weight for today will be required to be calculated assuming your app is refreshed on daily basis.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;This should give you custome sort option.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Régards,&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Sep 2018 20:44:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Sorting-order-by-expression-for-today-function/m-p/128825#M9031</guid>
      <dc:creator>thakkarrahul01</dc:creator>
      <dc:date>2018-09-15T20:44:54Z</dc:date>
    </item>
  </channel>
</rss>

