<?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: Create week number from date in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895520#M73889</link>
    <description>&lt;P&gt;So, based on that logic, it looks like the first seven days are always week 1, the next seven are always week 2, etc, no matter what the weekdays are?&lt;/P&gt;
&lt;P&gt;In that case, you could use something like:&lt;/P&gt;
&lt;P&gt;Floor((Date - MonthStart(Date))/7)+1&lt;/P&gt;
&lt;P&gt;Or a similar mathematical function to just figure out which set of seven days the date in question falls in&lt;/P&gt;</description>
    <pubDate>Mon, 21 Feb 2022 14:15:45 GMT</pubDate>
    <dc:creator>Or</dc:creator>
    <dc:date>2022-02-21T14:15:45Z</dc:date>
    <item>
      <title>Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895420#M73874</link>
      <description>&lt;P&gt;Hi ,&lt;/P&gt;
&lt;P&gt;I have below dates and i need to calculate week number for each month.&lt;/P&gt;
&lt;P&gt;I tried using simple week(Date ) but it not giving me the correct output:-&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Aspiring_Developer_0-1645444016040.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/72724i5D3DFB1E049C0C23/image-size/large?v=v2&amp;amp;px=999" role="button" title="Aspiring_Developer_0-1645444016040.png" alt="Aspiring_Developer_0-1645444016040.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Here the date format is DD/MM/YYYY and 17 Feb is not the 7 the week ., it should be 3 as it is the 3rd week of the month.&lt;/P&gt;
&lt;P&gt;How can I populate the week number for each month ?&lt;/P&gt;
&lt;P&gt;Can anyone please help ?&lt;/P&gt;
&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/46628"&gt;@sunny_talwar&lt;/a&gt;&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/336"&gt;@Kushal_Chawda&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 11:50:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895420#M73874</guid>
      <dc:creator>Aspiring_Developer</dc:creator>
      <dc:date>2022-02-21T11:50:32Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895421#M73875</link>
      <description>&lt;P&gt;This depends on what your definition of "week of the month" is. There are multiple methods for splitting weeks across years and months, so there's no one solution. Depending on which one you want to achieve, the required formulas are different. &lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 11:54:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895421#M73875</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2022-02-21T11:54:39Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895497#M73885</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6142"&gt;@Or&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wish to achieve the week distribution for each month .&lt;/P&gt;
&lt;P&gt;I have dates commencing from year 2010 till now.&lt;/P&gt;
&lt;P&gt;I wish to achieve below set of format :-&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Aspiring_Developer_0-1645452455612.png" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/72737iEAC47853A69F91FB/image-size/large?v=v2&amp;amp;px=999" role="button" title="Aspiring_Developer_0-1645452455612.png" alt="Aspiring_Developer_0-1645452455612.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What should i do ? &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 14:07:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895497#M73885</guid>
      <dc:creator>Aspiring_Developer</dc:creator>
      <dc:date>2022-02-21T14:07:51Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895510#M73888</link>
      <description>&lt;P&gt;That doesn't answer the question - how are you determining the week numbers within a month?&lt;/P&gt;
&lt;P&gt;If you're looking for the same logic as the regular week() function, you can use 1+ Week(Date) - Week(MonthStart(Date))&amp;nbsp; (in your example, it'd be 1 + 7 - 5 =&amp;nbsp; 3), but this may not work as you expect depending on the desired logic and which day the month happens to start/end on. &lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 14:02:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895510#M73888</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2022-02-21T14:02:13Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895520#M73889</link>
      <description>&lt;P&gt;So, based on that logic, it looks like the first seven days are always week 1, the next seven are always week 2, etc, no matter what the weekdays are?&lt;/P&gt;
&lt;P&gt;In that case, you could use something like:&lt;/P&gt;
&lt;P&gt;Floor((Date - MonthStart(Date))/7)+1&lt;/P&gt;
&lt;P&gt;Or a similar mathematical function to just figure out which set of seven days the date in question falls in&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 14:15:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1895520#M73889</guid>
      <dc:creator>Or</dc:creator>
      <dc:date>2022-02-21T14:15:45Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1896199#M73934</link>
      <description>&lt;LI-CODE lang="markup"&gt;Div(Day(Date)-1,7)+1&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 22 Feb 2022 20:36:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1896199#M73934</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2022-02-22T20:36:21Z</dc:date>
    </item>
    <item>
      <title>Re: Create week number from date</title>
      <link>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1896216#M73935</link>
      <description>&lt;LI-CODE lang="markup"&gt;Ceil(Day(Date)/7)&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 22 Feb 2022 21:16:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-week-number-from-date/m-p/1896216#M73935</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2022-02-22T21:16:03Z</dc:date>
    </item>
  </channel>
</rss>

