Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am new to qlikview.I want to add a specific cell value as column for all data in that file. I have found a solution but when i put the same code in loop i got wrong result.I am not sure where i am wrong.
My output should be like below screenshot
but i got the below output.
Script i tried
sub ScanFolder(Root)
for each FileExtension in 'xlsx'
for each FoundFile in filelist( Root & '\*.' & FileExtension)
FileData:
LOAD Sno,
Cust,
Prod,
[Sold Qty],
Price
FROM
[$(FoundFile)] (ooxml, embedded labels, table is Sheet1, filters(
Remove(Row, RowCnd(Interval, Pos(Top, 1), Pos(Top, 1), Select(1, 0)))
));
LOAD
B as Country
FROM
[$(FoundFile)] (ooxml, explicit labels, table is Sheet1)
WHERE RecNo() =1;
next FoundFile
next FileExtension
end sub
Call ScanFolder('C:\Users\Tamilarasu.Nagaraj\Desktop\New folder (2)') ;
Attached sample files. Can anyone help me.
Thank you in advance.
Kind Regards,
Tamil
Nice and thank you for the explanation. Simon.
Marc: It's fine now. and have a nice day.