<?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: Multiple file upload creating Syntax in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609197#M1104948</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Loading all files into a single temporary table before doing the preceding loads on a resident load (as Gysbert suggests) will work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tend to avoid the issue though by not using * to load from multiple files, if you change the code to load each file at a time using a loop then the preceding load does not cause problems:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;for each vFile in FileList('&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;.\ProcessedData_oAuth_*.txt')&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp; LOAD&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; *,&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(index('.jpg.ico.gif.png',Extension) &amp;gt; 0, 'Yes', 'No') as IsImage&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [rest of your load here]&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @11 as ResponseTimeinMS&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp; FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp; $(vFile)&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; (txt, codepage is 1252, no labels, delimiter is spaces, msq);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;next&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are other advantages of this approach, including the fact you can add extra logic inside the loop - perhaps a trace statement to say which file is being loaded or an if statement to avoid some files (eg. ~ prefixed files when loading from XLS).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps.&lt;/P&gt;&lt;P&gt;Steve&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 22 Mar 2014 08:14:41 GMT</pubDate>
    <dc:creator>stevedark</dc:creator>
    <dc:date>2014-03-22T08:14:41Z</dc:date>
    <item>
      <title>Multiple file upload creating Syntax</title>
      <link>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609195#M1104946</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;Can anyone help me with my LOAD Script? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am doing a multiple file upload but it is removing some lines as QlikView does not recognize these files being the 'same', creating a Syntax. Below is my LOAD Script. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I believe it is using my first data as the 'main' data and then trying to consolidate data. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I believe the error is somewhere at the top (in bold).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please help!!! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD*,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; if(index('.jpg.ico.gif.png',Extension) &amp;gt; 0, 'Yes', 'No') as IsImage;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD*,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; if(index(Page, '.', -1) &amp;gt; 0, mid(Page, index(Page, '.', -1)), '') as Extension;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD*,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; if(index(URL, '?') &amp;gt; 0, mid(URL,1, index(URL, '?') -1), URL) as Page,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; if(index(URL, '?') &amp;gt; 0, mid(URL,index(URL, '?')+1), '') as Params;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD*,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; daystart(DateTime) as Date,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; mid(RequestURI, index(RequestURI, ' ', 1), index(RequestURI, ' ', 2) - index(RequestURI, ' ', 1)) as URL,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; mid(RequestURI, index(RequestURI, ' ', 2)) as Protocol,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp; if(index(Track, '/', 3) &amp;gt; 0, mid(Track, index(Track, '/', 2) + 1, (index(Track, '/', 3) - index(Track, '/', 2)) - 1), '') as ReferrerSite;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp; filename() as DateHour,&lt;/P&gt;&lt;P&gt;&amp;nbsp; @1 as RemoteHost,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; date(date#(mid(@4, 2, 21), 'DD/MMM/YYY:hh:mm:ss'), 'DD MMM YYYY hh:mm:ss') as DateTime,&lt;/P&gt;&lt;P&gt;&amp;nbsp; date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'DD/MMM/YYYY hh:mm') as DateTimeNoSec,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Timestamp#(date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'YYYY')) as Year,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Timestamp#(date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'MMM')) as Month,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Timestamp#(date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'DD')) as Day,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Timestamp#(date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'hh')) as Hour,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Timestamp#(date(date#(mid(@4, 2, 17), 'DD/MMM/YYY:hh:mm'), 'mm')) as Minute,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; replace(@5, ']', '') as TimeZone, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @2 as FromIdentifier,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @3 as RemoteUser,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @4 as RequestTime,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; mid(@5, 1, index(@5, ' ', 1)) as Method,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @5 as RequestURI,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @6 as HTTPstatus, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @7 as Bytes, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @8 as ForwardedIP, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @9 as Track, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @10 as RemoteHostIP, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @11 as ResponseTimeinMS&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;.\ProcessedData_oAuth_*.txt&lt;/P&gt;&lt;P&gt;(txt, codepage is 1252, no labels, delimiter is spaces, msq);&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Mar 2014 23:05:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609195#M1104946</guid>
      <dc:creator />
      <dc:date>2014-03-21T23:05:53Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple file upload creating Syntax</title>
      <link>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609196#M1104947</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The preceding loads are only applied to the first .txt file. You first want to load the data from all the files into one table and then create the other fields in another load statement using a resident load (or store the intermediate table to a qvd first and load from that qvd).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Mar 2014 08:03:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609196#M1104947</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2014-03-22T08:03:48Z</dc:date>
    </item>
    <item>
      <title>Re: Multiple file upload creating Syntax</title>
      <link>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609197#M1104948</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Loading all files into a single temporary table before doing the preceding loads on a resident load (as Gysbert suggests) will work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tend to avoid the issue though by not using * to load from multiple files, if you change the code to load each file at a time using a loop then the preceding load does not cause problems:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;for each vFile in FileList('&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;.\ProcessedData_oAuth_*.txt')&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp; LOAD&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; *,&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if(index('.jpg.ico.gif.png',Extension) &amp;gt; 0, 'Yes', 'No') as IsImage&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG style="font-style: inherit; font-family: inherit;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; [rest of your load here]&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; @11 as ResponseTimeinMS&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp; FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp; $(vFile)&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; (txt, codepage is 1252, no labels, delimiter is spaces, msq);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;next&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are other advantages of this approach, including the fact you can add extra logic inside the loop - perhaps a trace statement to say which file is being loaded or an if statement to avoid some files (eg. ~ prefixed files when loading from XLS).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps.&lt;/P&gt;&lt;P&gt;Steve&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Mar 2014 08:14:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Multiple-file-upload-creating-Syntax/m-p/609197#M1104948</guid>
      <dc:creator>stevedark</dc:creator>
      <dc:date>2014-03-22T08:14:41Z</dc:date>
    </item>
  </channel>
</rss>

