Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
BootCam
Creator
Creator

Downloading multiple .xml.gz file from FTP

Hi I am trying to get bunch of .xml.gz file from ftp and copying them to my local folder with the below script in qlikview. But its not working.

 

If i want to copy files from one local folder to another local folder it works. But for ftp it doesnt work.

 

BatFile:

Load

'This is a batch file test' As [@echo off]

AutoGenerate(1);

 

Let vDate = Date(Today(),'YYYY-MM-DD');

Let vExt = '*.xml.gz';

 

 

For Each vFile in FileList('ftp://Username:Password.982@ServerName:21/folder/*.xml.gz')

 

BatFile:

FIRST 1 Load

'COPY $(vFile) C:\Users\Documents\TestFolder1\$(vDate)'&'_' & SubField('$(vFile)', '\', -1) As [@echo off]

FROM $(vFile) (txt);

 

Next

 

Store BatFile into 'C:\Users\Documents\ABC'.bat (txt);

 

Drop Table BatFile;

 

EXECUTE C:\Users\Documents\ABC.bat;

 

 

Let me know if you have any questions.

 

Thnaks,

Sk

0 Replies