<?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: Counting Days in Specific Month between Two Dates in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202870#M627050</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That is what I propose, yes, but it's simpler than I suspect you are imagining. See attached. Script and chart below.&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/142714_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Rentals:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,recno() as RentalID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;INLINE [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Apartment,Name,Start,End&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;217,Alice,1/2/2009,1/2/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;217,Bob,1/16/2009,3/27/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;105,Carla,2/3/2009,3/11/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Occupancy:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt; RentalID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,Start+iterno()-1 as Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;RESIDENT Rentals&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;WHILE Start+iterno()-1 &amp;lt;= End&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Calendar:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,monthstart(Date) as Month&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD makedate(2008,12,31)+recno() as Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE 90&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The potential problem is memory. If you're tracking tens of thousands of apartments over the past 30 years, say, this would yield a very large table. It can be dramatically shrunk down if that's a problem, but doing so IS complicated. Maybe I should write a subroutine that builds the smaller but more complicated version automatically - give it a table, a key field, the Start and End fields, and the field name for the date it produces, and it builds the whole data structure and all the data for you. Something like that. Hmmm. Hmmm. Probably more time than I can devote right now, and you probably don't need it. It's hard for me to imagine you tracking enough apartments over a long enough time frame to cause a real problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Nov 2016 16:43:37 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2016-11-02T16:43:37Z</dc:date>
    <item>
      <title>Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202865#M627045</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;Hello,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;I am trying to create set analysis that will calculate the the number of days that fall within a certain month.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;&lt;IMG __jive_id="142571" alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/142571_Capture.PNG" style="height: auto;" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;Any help would be greatly appreciated!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Verdana, Arial, Tahoma, Calibri, Geneva, sans-serif; font-size: 13px; background-color: #fafafa;"&gt;Thx&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Nov 2016 09:14:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202865#M627045</guid>
      <dc:creator />
      <dc:date>2016-11-01T09:14:44Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202866#M627046</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What's the use case here?&lt;/P&gt;&lt;P&gt;Can you describe your data, charts, expression or upload a small sample application?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Marco&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Nov 2016 22:55:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202866#M627046</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2016-11-01T22:55:59Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202867#M627047</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Set analysis isn't responsive to the values of your dimensions in the way it seems you want here. You'll need another solution. Assuming your Start and End are values in some table that has some other key...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Name, Start, End&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Alice,1/2/2009,1/2/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Bob&amp;nbsp; ,1/16/2009,3/27/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Carla,2/3/2009,3/11/2009&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;...a probably common way of doing it is to create a table that has one row for each key and each date between start and end for that key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Name, Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Alice,1/2/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Bob&amp;nbsp; ,1/16/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Bob&amp;nbsp; ,1/17/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Bob&amp;nbsp; ,3/26/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Bob&amp;nbsp; ,3/27/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Carla,2/3/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Carla,2/4/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Carla,3/10/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Carla,3/11/2009&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Connect your Date to a master calendar. Then your expression is just this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;count(distinct Date)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Nov 2016 23:23:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202867#M627047</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2016-11-01T23:23:42Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202868#M627048</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Marco,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your reply. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a table with holiday apartment booking details and I would like to have a table in QlikView showing Occupancy % by month per apartment. So for each month I need a percentage of nights booked over the total for that month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this gives you a bit more clarity.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Nov 2016 14:49:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202868#M627048</guid>
      <dc:creator />
      <dc:date>2016-11-02T14:49:07Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202869#M627049</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your reply.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So what you are proposing is to loop through all the records in the table and create a new table with individual rows for all days between Start and End date? That sounds quite complicated to me. &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt; Is there a simple way to achieve this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Nov 2016 14:51:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202869#M627049</guid>
      <dc:creator />
      <dc:date>2016-11-02T14:51:37Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202870#M627050</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That is what I propose, yes, but it's simpler than I suspect you are imagining. See attached. Script and chart below.&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/142714_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Rentals:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,recno() as RentalID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;INLINE [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Apartment,Name,Start,End&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;217,Alice,1/2/2009,1/2/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;217,Bob,1/16/2009,3/27/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;105,Carla,2/3/2009,3/11/2009&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;];&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Occupancy:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt; RentalID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,Start+iterno()-1 as Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;RESIDENT Rentals&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;WHILE Start+iterno()-1 &amp;lt;= End&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Calendar:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,monthstart(Date) as Month&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD makedate(2008,12,31)+recno() as Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE 90&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The potential problem is memory. If you're tracking tens of thousands of apartments over the past 30 years, say, this would yield a very large table. It can be dramatically shrunk down if that's a problem, but doing so IS complicated. Maybe I should write a subroutine that builds the smaller but more complicated version automatically - give it a table, a key field, the Start and End fields, and the field name for the date it produces, and it builds the whole data structure and all the data for you. Something like that. Hmmm. Hmmm. Probably more time than I can devote right now, and you probably don't need it. It's hard for me to imagine you tracking enough apartments over a long enough time frame to cause a real problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Nov 2016 16:43:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202870#M627050</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2016-11-02T16:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202871#M627051</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;one way to do so might be:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="QlikCommunity_Thread_238292_Pic2.JPG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/142752_QlikCommunity_Thread_238292_Pic2.JPG" style="height: 309px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="QlikCommunity_Thread_238292_Pic1.JPG" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/142753_QlikCommunity_Thread_238292_Pic1.JPG" style="height: 215px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_14781249680208282 jive_text_macro" jivemacro_uid="_14781249680208282"&gt;
&lt;P&gt;tabBookings:&lt;/P&gt;
&lt;P&gt;LOAD RecNo() as BookID, *&lt;/P&gt;
&lt;P&gt;Inline [&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; AptID, Start, End&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; A, 01/02/2009, 01/02/2009&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; A, 01/16/2009, 03/27/2009&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; A, 04/25/2009, 07/12/2009&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; B, 02/03/2009, 03/11/2009&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; B, 03/18/2009, 08/21/2009&lt;/P&gt;
&lt;P&gt;];&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;tabMonthOccup:&lt;/P&gt;
&lt;P&gt;LOAD *,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Num(DaysBooked/DaysInMonth,'0%') as Occupancy;&lt;/P&gt;
&lt;P&gt;LOAD *,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; MonthName(MonthBookStart) as MonthBook,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; MonthBookEnd-MonthBookStart+1 as DaysBooked,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; MonthStart(MonthBookStart,1)-MonthStart(MonthBookStart) as DaysInMonth;&lt;/P&gt;
&lt;P&gt;LOAD BookID,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(RangeMax(Start,MonthStart(Start,IterNo()-1))) as MonthBookStart,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(RangeMin(End&amp;nbsp; ,MonthStart(Start,IterNo())-1)) as MonthBookEnd&lt;/P&gt;
&lt;P&gt;Resident tabBookings&lt;/P&gt;
&lt;P&gt;While MonthStart(Start,IterNo()-1)&amp;lt;=End;&lt;/P&gt;
&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would suggest to go with John's solution however, as it should deliver a far more flexible result especially when adding some additional calendar fields &lt;SPAN style="font-size: 10pt;"&gt;(drill down capabilities, responsiveness to date related selections ...).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this helps&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Marco&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Nov 2016 22:22:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202871#M627051</guid>
      <dc:creator>MarcoWedel</dc:creator>
      <dc:date>2016-11-02T22:22:28Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202872#M627052</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I went for the solution you proposed and managed to get the result I was looking for! I only want to track around 50 apartments so I am sure I will not be running into memory problems! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Many thanks for your help with this!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Nov 2016 07:57:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202872#M627052</guid>
      <dc:creator />
      <dc:date>2016-11-04T07:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: Counting Days in Specific Month between Two Dates</title>
      <link>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202873#M627053</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Marco,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your reply. As you also suggested I went with John's solution I got the results I was looking for. I would like to thank you for your support with this issue!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Aaron&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Nov 2016 07:58:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Counting-Days-in-Specific-Month-between-Two-Dates/m-p/1202873#M627053</guid>
      <dc:creator />
      <dc:date>2016-11-04T07:58:36Z</dc:date>
    </item>
  </channel>
</rss>

