Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Reading multiple files from a directory

Hi,

I want to make a Qlickview script to read multiples files from a diirectory.

I want to know if it is posible to do something like that:

1) execute comand in S.O. win from Qlick to get the files contanined in a directory (dir) -> load the filenames in a resident table

2) read this resident table row a row and for each filename make a load (load * from filename)

Thanks in advance,

Labels (1)
3 Replies
Clever_Anjos
Support
Support

Why don´t you use the usual

for Each file in FileList('Path\*.qvd')

  LOAD *

  FROM [$(file)](qvd(;

next

maxgro
MVP
MVP

I think this is what you want but in a easier way


FOR Each File in filelist ('.\*.log' )          // or *.*

  trace read $(File);

  Table_$(File):

  LOAD *

  FROM

  '$(File)'

  (txt, unicode, no labels, delimiter is '\t', msq);

NEXT File;

rwunderlich
MVP
MVP

Or just use a wildcard:

LOAD * FROM *.csv;