Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have 3 excel files, that is 2700,2701,2702. How can i load these files using loop concept.
Could anyone pls help me.
Try to read this threads
https://community.qlik.com/docs/DOC-7503
Or
Dynamically Loading Multiple Excel Files
Regards,
Anand
Hi,
You can load all the files using wildcard characters like below, no need of loops here
Data:
LOAD
*,
FileName() AS ExcelFileName
FROM *.xlsx
-----------------;
Hope this helps you.
Regards,
jagan.
I'm not getting clear explanation. Could u pls try to explain me in some other way. Beca i have multiple excel files. not excel sheets.
Why not run this script?
I am hoping you r having same fields in all the excel files......
Test:
Load
*
From ExcelFielName27*; // * is here a wild card char and load all the files starting with '27' into one file, say Test
Hi,
As jagan mohan rao appala says
You can load all the files using wildcard characters like below, no need of loops here
Data: //This is the name of the table you will create
LOAD // This lets qlikview know you are loading new data
*, // The * means load all the fields in the spreadsheet
FileName() AS ExcelFileName // This statement will let you know which spreadsheet the data came from
FROM *.xlsx // this will load all the spreadsheets (Excel Files) in the folder
If you use the "load table" wizard then everything should be straight forward
Hi Silambarasan,
Try something like this:
Set vConcatenate = ;
sub ScanFolder(Root)
for each FileExtension in 'csv'
for each FoundFile in filelist( Root & '\*.' & FileExtension)
FileList:
$(vConcatenate)
LOAD *, '$(FoundFile)' as SourceFile
FROM [$(FoundFile)] (txt, codepage is 1252, embedded labels, delimiter is ',', msq, header is 2 lines);
Set vConcatenate = Concatenate;
next FoundFile
next FileExtension
for each SubDirectory in dirlist( Root & '\*' )
call ScanFolder(SubDirectory)
next SubDirectory
end sub
Call ScanFolder('C:\Users\hic\Documents\2012\Work\QV Apps\DoDir') ;
Thanks,
Sangram.