<?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 FOR ... NEXT and DO until - part II in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/FOR-NEXT-and-DO-until-part-II/m-p/757761#M269705</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Hi All,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;with a help from Marco Wedel (&lt;A _jive_internal="true" href="https://community.qlik.com/thread/143360"&gt;thread&lt;/A&gt;) I got the below script which requests data from websites in a loop until the data is loaded (due to web server issues a load ends up with no data so needs to be loaded again). Now I need to tune the script as described below.&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;
&lt;P&gt;Links:&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LOAD * Inline [&amp;nbsp; &lt;/P&gt;
&lt;P&gt;Link&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.rates1.com"&gt;http://www.rates1.com&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.rates2.com"&gt;http://www.rates2.com&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;];&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vNoOfLinks = NoOfRows('Links');&amp;nbsp; &lt;/P&gt;
&lt;P&gt;FOR i=0 to $(vNoOfLinks)-1;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vLink = Peek('Link',$(i),'Links');&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vNoOfRowsRates = Alt(NoOfRows('Rates'),0);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;DO&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; Rates:&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; LOAD&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; [@1:n] as Data&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; FROM $(vLink) (fix, utf8);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LOOP until NoOfRows('Rates') &amp;gt; $(vNoOfRowsRates);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;NEXT; &lt;/P&gt;
&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt;"&gt;Table 'Rates' consists of sets of data from Links. Each Link set (except the last one) should have exactly 10 records including '*increase*' string. However, due to web server issue, a load from a Link happens to return less than 10 records with the string. In such cases &lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: inherit; font-size: 10pt; font-style: inherit; font-weight: inherit;"&gt;I need to load the data again from this very Link. The last Link set may return less than 10 records and that's ok.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Any idea how to play this scenario?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Regards,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Przemek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 Dec 2014 10:42:59 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-12-02T10:42:59Z</dc:date>
    <item>
      <title>FOR ... NEXT and DO until - part II</title>
      <link>https://community.qlik.com/t5/QlikView/FOR-NEXT-and-DO-until-part-II/m-p/757761#M269705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Hi All,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;with a help from Marco Wedel (&lt;A _jive_internal="true" href="https://community.qlik.com/thread/143360"&gt;thread&lt;/A&gt;) I got the below script which requests data from websites in a loop until the data is loaded (due to web server issues a load ends up with no data so needs to be loaded again). Now I need to tune the script as described below.&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;
&lt;P&gt;Links:&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LOAD * Inline [&amp;nbsp; &lt;/P&gt;
&lt;P&gt;Link&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.rates1.com"&gt;http://www.rates1.com&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.rates2.com"&gt;http://www.rates2.com&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;];&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vNoOfLinks = NoOfRows('Links');&amp;nbsp; &lt;/P&gt;
&lt;P&gt;FOR i=0 to $(vNoOfLinks)-1;&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vLink = Peek('Link',$(i),'Links');&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LET vNoOfRowsRates = Alt(NoOfRows('Rates'),0);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;DO&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; Rates:&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; LOAD&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; [@1:n] as Data&amp;nbsp; &lt;/P&gt;
&lt;P&gt;&amp;nbsp; FROM $(vLink) (fix, utf8);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;LOOP until NoOfRows('Rates') &amp;gt; $(vNoOfRowsRates);&amp;nbsp; &lt;/P&gt;
&lt;P&gt;NEXT; &lt;/P&gt;
&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 10pt;"&gt;Table 'Rates' consists of sets of data from Links. Each Link set (except the last one) should have exactly 10 records including '*increase*' string. However, due to web server issue, a load from a Link happens to return less than 10 records with the string. In such cases &lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: inherit; font-size: 10pt; font-style: inherit; font-weight: inherit;"&gt;I need to load the data again from this very Link. The last Link set may return less than 10 records and that's ok.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Any idea how to play this scenario?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Regards,&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Przemek&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2014 10:42:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FOR-NEXT-and-DO-until-part-II/m-p/757761#M269705</guid>
      <dc:creator />
      <dc:date>2014-12-02T10:42:59Z</dc:date>
    </item>
    <item>
      <title>Re: FOR ... NEXT and DO until - part II</title>
      <link>https://community.qlik.com/t5/QlikView/FOR-NEXT-and-DO-until-part-II/m-p/757762#M269706</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Anyone any idea, please?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Dec 2014 21:16:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/FOR-NEXT-and-DO-until-part-II/m-p/757762#M269706</guid>
      <dc:creator />
      <dc:date>2014-12-10T21:16:07Z</dc:date>
    </item>
  </channel>
</rss>

