Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I'm trying to load 5 files from the folder of 1000 files.
I have stored file names in vFilenames.
vFilenames = abg, dhjk, qwe, qwee, gsdf;
How can i load only these 5 files from the folder, instead of loading all files and then filtering by the filebasename()?
FOR EACH File in FileList('$(vFolder)\$(vFilenames).QVD') //Storing filenames in the variable 'File'
Table1:
LOAD *
FROM [$(File)] (qvd);
NEXT
The above is not working.
Any help is highly appreciated.
My 2 cents....
If you had to stay with the comma delimited variable, I'd have gone with:
Set vFileList='201601,201602,201603';
Set vFolder = '\\Folder\';
let FileCount=SubStringCount((vFileList),',')+1;
FOR i=1 to $(FileCount)
Let vFile=SubField(vFileList,',',$(i));
Let vQVD= (vFolder) & '\'& $(vFile) & '.qvd';
Table1:
LOAD *
FROM $(vQVD)(qvd);
NEXT