<?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: Removing headers from csv in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106525#M16688</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Qlikview 11 let us down.&amp;nbsp; Using macros on the server requires the IE Plugin.&lt;/P&gt;&lt;P&gt;We're investigating a windows scheduled task to open the document, reload and run the macro.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 28 Sep 2018 12:14:28 GMT</pubDate>
    <dc:creator>markp201</dc:creator>
    <dc:date>2018-09-28T12:14:28Z</dc:date>
    <item>
      <title>Removing headers from csv</title>
      <link>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106524#M16687</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've seen a few various ideas but we required one which removed the headers from a table in the load script.&lt;/P&gt;&lt;P&gt;Normally, this would be an ETL process but Qlikview sufficed&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We loaded the table, saved to a csv and called the macro&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;Table:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;SELECT &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;&amp;nbsp; * &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;FROM &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;&amp;nbsp; table&lt;/SPAN&gt;&lt;/P&gt;&lt;P&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;&lt;SPAN style="font-family: courier new, courier;"&gt;STORE Table INTO [...].csv (txt, delimiter is '|'); &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;DROP TABLE Table;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;&lt;STRONG&gt;LET vx = RemoveHeaders();&lt;/STRONG&gt;&lt;/SPAN&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;Below is the macro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;Function RemoveHeaders()&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;SET objFSO = CreateObject("Scripting.FileSystemObject")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;text = ""&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;Lines = 0&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;SET objCSVFile = objFSO.OpenTextFile("C:\users\....csv",1)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;objCSVFile.ReadLine&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;DO WHILE NOT objCSVFile.AtEndOfStream&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;&amp;nbsp; text = text &amp;amp; objCSVFile.ReadLine &amp;amp; vbCrLf&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;&amp;nbsp; Lines = Lines + 1&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;LOOP&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;objCSVFile.Close&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;SET objResultFile = objFSO.CreateTextFile("c:\users\...csv",true)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new, courier;"&gt;objResultFile.WriteLine "Report name,Date (need function)"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;objResultFile.Write text&lt;/P&gt;&lt;P&gt;objResultFile.Write Lines&lt;/P&gt;&lt;P&gt;objResultFile.Close&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End Function&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Nice feature is this will work for any number of columns.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 25 Sep 2018 11:51:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106524#M16687</guid>
      <dc:creator>markp201</dc:creator>
      <dc:date>2018-09-25T11:51:51Z</dc:date>
    </item>
    <item>
      <title>Re: Removing headers from csv</title>
      <link>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106525#M16688</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Qlikview 11 let us down.&amp;nbsp; Using macros on the server requires the IE Plugin.&lt;/P&gt;&lt;P&gt;We're investigating a windows scheduled task to open the document, reload and run the macro.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2018 12:14:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106525#M16688</guid>
      <dc:creator>markp201</dc:creator>
      <dc:date>2018-09-28T12:14:28Z</dc:date>
    </item>
    <item>
      <title>Re: Removing headers from csv</title>
      <link>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106526#M16689</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;I had almost same problem but with xml-files. Here's part of my script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXECUTE cmd.exe /c more +1 "$(vStore)test.xml" &amp;gt; "$(vStore)$(vCopiedFile)";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have loop that checks one folder and removes some lines from all files that haven't been handled.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;More command with +1 drops one line from file start away. You could make this part of some transform layer and end application would load only modified files.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You have to allow execute statement for file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Miikka&lt;/P&gt;&lt;P&gt;Climber Finland&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Sep 2018 12:33:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Removing-headers-from-csv/m-p/106526#M16689</guid>
      <dc:creator>miikkaqlick</dc:creator>
      <dc:date>2018-09-28T12:33:39Z</dc:date>
    </item>
  </channel>
</rss>

