Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Cummunity,
I have a problem and hope you can help me.
I have many CSV files in one a Space. "DKV_SIS 2023-01-01.csv", "DKV_SIS 2023-01-02", "DKV_SIS 2023-01-03", ....
I would like to create an app where all CSV files are dynamically saved in a new QVD.
To do this, I need to be able to read out how many files there are in the Space and what the files are called.
Then load the individual CSVs with a loop and then save them in a QVD.
Is it possible to read all files from a Space and load them one after the other?
I use Qlik Sense Saas.
Thank you very much
Handren
Hi @HTaher ,
You could try something like
for each file in FileList('lib://YourSpace:DataFiles/DKV_SIS*.csv')
load '$(file)' as Name AutoGenerate 1;
mydata:
load * from ['$(file)'] (txt, utf8, embedded labels, delimiter is ',');
next file
store mydata into ['lib://YourSpace:DataFiles/mydata.qvd'];
See if that works.
Best
Björn
Hi @HTaher ,
You could try something like
for each file in FileList('lib://YourSpace:DataFiles/DKV_SIS*.csv')
load '$(file)' as Name AutoGenerate 1;
mydata:
load * from ['$(file)'] (txt, utf8, embedded labels, delimiter is ',');
next file
store mydata into ['lib://YourSpace:DataFiles/mydata.qvd'];
See if that works.
Best
Björn