Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Experts,
i have one folder like (folder name) "SOURCE" in this folder having 5 Excel sheets like
Data 2016_4_25.xlsx
Data 2016_4_24.xlsx
Data 2016_4_23.xlsx
Data 2016_4_22.xlsx
Data 2016_4_21.xlsx
i will load all files at a time by using *
here my requirement is how can i create 5 qvd's.(separate qvd for each sheet) .
Something along these lines
FOR EACH vFile IN FILELIST('.\Data 2016_4_*.xlsx')
TEMP:
LOAD Field1,
Field2,
...
FROM [$(vFile)]
(...);
STORE TEMP INTO [$(vFile).qvd] (qvd);
DROP TABLE TEMP;
NEXT vFile
If your final goal is to produce the qvds, I would use FOR EACH .. IN FILELIST (..)
to iterate over your excel files, load one after the other and store to QVD right away.
Hi Swuehl,
please share with "FOR EACH".
Something along these lines
FOR EACH vFile IN FILELIST('.\Data 2016_4_*.xlsx')
TEMP:
LOAD Field1,
Field2,
...
FROM [$(vFile)]
(...);
STORE TEMP INTO [$(vFile).qvd] (qvd);
DROP TABLE TEMP;
NEXT vFile
Here is the sample:
Hi Swuehl,
Thanks for your response
Regards,
Mahesh