<?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 Networking days in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326933#M1184559</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can we can apply the function networking days into a calendar by country and what is the strutucture of this file have to be.&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;Fernando. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Nov 2011 13:51:22 GMT</pubDate>
    <dc:creator />
    <dc:date>2011-11-17T13:51:22Z</dc:date>
    <item>
      <title>Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326933#M1184559</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can we can apply the function networking days into a calendar by country and what is the strutucture of this file have to be.&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;Fernando. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 13:51:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326933#M1184559</guid>
      <dc:creator />
      <dc:date>2011-11-17T13:51:22Z</dc:date>
    </item>
    <item>
      <title>Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326934#M1184561</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; &lt;SPAN class="Bold"&gt;networkdays&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Returns the number of working days (Monday-Friday) between and including &lt;SPAN style="font-style: italic;"&gt;start_date&lt;/SPAN&gt; and &lt;SPAN style="font-style: italic;"&gt;end_date&lt;/SPAN&gt; taking into account any optionally listed &lt;SPAN style="font-style: italic;"&gt;holidays&lt;/SPAN&gt;. All parameters should be valid dates or timestamps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;networkdays&lt;/SPAN&gt; (startdate, enddate, holidaydate1, holidaydate2,holidaydate3,holidaydate4.......) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for example &lt;/P&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;networkdays&lt;/SPAN&gt; ('2006-12-18', '2006-12-31', '2006-12-25', '2006-12-26') &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this help&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 13:56:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326934#M1184561</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-11-17T13:56:51Z</dc:date>
    </item>
    <item>
      <title>Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326935#M1184562</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; also not include holidaydate(optional)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;example&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="Bold"&gt;networkdays&lt;/SPAN&gt; ('2006-12-18', '2006-12-31') &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 13:57:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326935#M1184562</guid>
      <dc:creator>SunilChauhan</dc:creator>
      <dc:date>2011-11-17T13:57:53Z</dc:date>
    </item>
    <item>
      <title>Re: Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326936#M1184564</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your reply , but is possible apply the&amp;nbsp; function&amp;nbsp; networking days against one table with the working days?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Fernando.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 14:07:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326936#M1184564</guid>
      <dc:creator />
      <dc:date>2011-11-17T14:07:06Z</dc:date>
    </item>
    <item>
      <title>Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326937#M1184566</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Should be possible, take a look at John's solution here:&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://community.qlik.com/message/131162#131162"&gt;http://community.qlik.com/message/131162&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 14:11:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326937#M1184566</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2011-11-17T14:11:54Z</dc:date>
    </item>
    <item>
      <title>Re: Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326938#M1184568</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Having different holidays by country would be more complicated than what I did in that thread, though.&amp;nbsp; Attached is one way to do it.&amp;nbsp; Again, we're generating a holiday list in a variable, but now we generate a pick(match()) to select the right holiday list by country.&amp;nbsp; I don't like that I have a separate load for each country, but I can't think of how to get around it.&amp;nbsp; It probably won't be a problem in practice since the tables involved at that point are small.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I completely made up these holidays, so don't look for them to make any sense.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's the script:&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;[Holidays]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD * INLINE [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Country, Holiday&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;USA, 3/15/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;USA, 3/10/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;USA, 2/15/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;USA, 1/1/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Mexico, 1/10/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Mexico, 2/15/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Mexico, 3/4/2011&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;Countries:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD text(fieldvalue('Country',recno())) as Country&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,recno() as Sequence&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE fieldvaluecount('Country')&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;AllCountries:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD concat(chr(39) &amp;amp; Country &amp;amp; chr(39),',',Sequence) as AllCountries&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;RESIDENT Countries&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;LET allholidays = '=pick(match(Country,' &amp;amp; peek('AllCountries') &amp;amp; ')'&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;FOR I = 1 TO noofrows('Countries')&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; AllHolidays:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; LOAD concat(num(Holiday),',') as AllHolidays RESIDENT Holidays WHERE Country = peek('Country',$(I)-1,'Countries');&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; LET allholidays = allholidays &amp;amp; ',' &amp;amp; chr(39) &amp;amp; peek('AllHolidays') &amp;amp; chr(39);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DROP TABLE AllHolidays;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;NEXT&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LET allholidays = allholidays &amp;amp; ')';&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;DROP TABLES &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Countries&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,AllCountries&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;[Dates]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD * INLINE [&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;03/05/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;03/14/2011&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;03/17/2011&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; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: arial,helvetica,sans-serif;"&gt;Then I made a list box with always one Country selected, and I used expressions like these.&lt;/SPAN&gt;&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; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;firstworkdate(Date,4,$(allholidays)) // in a straight table by Date&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;networkdays('1/1/2011',min(Date),$(allholidays))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Nov 2011 00:16:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326938#M1184568</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-11-18T00:16:50Z</dc:date>
    </item>
    <item>
      <title>Re: Networking days</title>
      <link>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326939#M1184569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Heh.&amp;nbsp; I meant to drop the Holiday table, then left it so you could see what the holidays actually were.&amp;nbsp; But if you're leaving it in the data model, then there's a MUCH simpler way to handle things.&amp;nbsp; Just define your variable like 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;=concat(num(Holiday),',')&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Nov 2011 00:22:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Networking-days/m-p/326939#M1184569</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-11-18T00:22:48Z</dc:date>
    </item>
  </channel>
</rss>

