Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi
i need to import several zipped CSV files from a FTP Server into the script directly. Do you know how to do this?
there is an option, but i never used it (i also have no FTP Server connection yet, so i never tried)
thanks
felipe
Qlikview can't read zipped csv files. You either need to store the csv files uncompressed on the ftp server or you have to use an external tool like curl or wget to download the zip files, then use a script to unzip the files. Then Qlikview can load the uncompressed csv files.
edit: enable the Use FTP option under Data from Files to retrieve files via ftp
Qlikview can't read zipped csv files. You either need to store the csv files uncompressed on the ftp server or you have to use an external tool like curl or wget to download the zip files, then use a script to unzip the files. Then Qlikview can load the uncompressed csv files.
edit: enable the Use FTP option under Data from Files to retrieve files via ftp
thanks
the files are comming unzipped, we changed this.
using the ftp option from QV, is it possible to get access to unzipped files located in a ftp server and to bring them to the QV Application? Or do i need a macro, what i also have.
I cannot try now with accessing directly the ftp server since i need some credentials, which i do not have, but just wanted to know
thanks
felipe
Try this: (with loop because wildcards don't work per ftp-load)
set ftp = 'ftp://USER:PASSWORD@YOURSERVER.com/';PASSWORD@YOURSERVER.com/';
set datafile = 'YOURFILE';
set ext = '.csv';
set typCSV = "(txt, codepage is 1252, embedded labels, delimiter is ';', no quotes)";
for i = 0 to $(vCounter)
let vZeitraum = date(AddMonths('01.02.2012', $(i)), 'YYYY_MM');
table:
Load *
FROM $(ftp)$(datafile)$(vZeitraum)$(ext)$(typCSV);
next
- Marcus
hi
thanks for the script, the vCounter should be the number of my datafiles in the ftp server, right?
Yes, a simple counter:
let vCounter = ((year(today() - 1) - year('01.02.2012')) * 12) + (month(today() - 1) - month('01.02.2012'))
to generate a YearMonth-stamp for the loop.
- Marcus
how can i create loop for every day? i want to load for everyday.. file is generated for every 1 min; deleted for 15days..
What is the sample file name format
csv 's