<?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: Order of weekdates with string in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839985#M1215209</link>
    <description>&lt;P&gt;I am concerned about the calculation of your week-year. In some situations the calendar year is not the same as the week's year.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; &lt;STRONG&gt;Year(MyDate)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Eg:&amp;nbsp; January 1th 2021 is in Week 53 2020, but your calculation will return the year 2021.&amp;nbsp;&lt;/P&gt;&lt;P&gt;It is better to avoid using Year() and rather use the &lt;A href="https://help.qlik.com/en-US/sense/November2020/Subsystems/Hub/Content/Sense_Hub/Scripting/DateAndTimeFunctions/weekyear.htm" target="_self"&gt;WeekYear()&lt;/A&gt; function when handling weeks. Like I've done below.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; &lt;STRONG&gt;WeekYear(MyDate)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 29 Sep 2021 07:38:05 GMT</pubDate>
    <dc:creator>Vegar</dc:creator>
    <dc:date>2021-09-29T07:38:05Z</dc:date>
    <item>
      <title>Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839971#M1215206</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I've created a dates to look like&amp;nbsp;&lt;/P&gt;&lt;P&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; Year(MyDate)&amp;nbsp;&lt;/P&gt;&lt;P&gt;However because I add 'Week' it becomes string and loses its order (without it its fine). However client really want its with "Week" or "W"&lt;/P&gt;&lt;P&gt;Any ideas?&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 07:15:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839971#M1215206</guid>
      <dc:creator>QlickySense</dc:creator>
      <dc:date>2021-09-29T07:15:12Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839975#M1215207</link>
      <description>&lt;P&gt;You can create a dual of your field to solve this.&lt;/P&gt;&lt;P&gt;Try to create your field like this:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Dual(&lt;/STRONG&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; Year(MyDate)&lt;STRONG&gt;,monthname(MyDate))&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 07:27:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839975#M1215207</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2021-09-29T07:27:03Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839982#M1215208</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;unfortunately It didnt work&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 07:34:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839982#M1215208</guid>
      <dc:creator>QlickySense</dc:creator>
      <dc:date>2021-09-29T07:34:27Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839985#M1215209</link>
      <description>&lt;P&gt;I am concerned about the calculation of your week-year. In some situations the calendar year is not the same as the week's year.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; &lt;STRONG&gt;Year(MyDate)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Eg:&amp;nbsp; January 1th 2021 is in Week 53 2020, but your calculation will return the year 2021.&amp;nbsp;&lt;/P&gt;&lt;P&gt;It is better to avoid using Year() and rather use the &lt;A href="https://help.qlik.com/en-US/sense/November2020/Subsystems/Hub/Content/Sense_Hub/Scripting/DateAndTimeFunctions/weekyear.htm" target="_self"&gt;WeekYear()&lt;/A&gt; function when handling weeks. Like I've done below.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Week(MyDate) &amp;amp; ' ' &amp;amp; 'Week' &amp;amp; Chr(13) &amp;amp; &lt;STRONG&gt;WeekYear(MyDate)&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 07:38:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839985#M1215209</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2021-09-29T07:38:05Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839988#M1215211</link>
      <description>&lt;P&gt;Thanks, I'll apply that. However still don't resolved sorting problem, with WeekYear it is the same, unfortunately&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 07:42:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1839988#M1215211</guid>
      <dc:creator>QlickySense</dc:creator>
      <dc:date>2021-09-29T07:42:30Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840025#M1215216</link>
      <description>&lt;P&gt;We misunderstand each other. I assumed you would use my suggestion to define your field in the script, replacing your current field.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 09:32:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840025#M1215216</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2021-09-29T09:32:35Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840033#M1215218</link>
      <description>&lt;P&gt;It converts nicely, but my problem is that if I get this field in X-axis it appears in random order like 4 Week 2020 and then 52 Week 2020, I'd like to order them by year and week&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 09:43:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840033#M1215218</guid>
      <dc:creator>QlickySense</dc:creator>
      <dc:date>2021-09-29T09:43:40Z</dc:date>
    </item>
    <item>
      <title>Re: Order of weekdates with string</title>
      <link>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840083#M1215226</link>
      <description>&lt;P&gt;Check the object properties that your chart is ordered by your dual value dimension and that the sort order of your dimension is set to numeric sorting.&lt;/P&gt;</description>
      <pubDate>Wed, 29 Sep 2021 12:06:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Order-of-weekdates-with-string/m-p/1840083#M1215226</guid>
      <dc:creator>Vegar</dc:creator>
      <dc:date>2021-09-29T12:06:34Z</dc:date>
    </item>
  </channel>
</rss>

