Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have below script in qvw to load 41 excel sheets data at a time. when I am reloading it is showing an error filed not found: <ID>[_xlnm_#FilterDatabase].
can anyone suggest me please how can I set this.
Thanks.
tables:
SQLTables;
DISCONNECT;
Tables1:
load
*,
replace(TABLE_NAME,chr(39),'') as NEW
resident tables;
DROP Table tables;
let var=NoOfRows('Tables1');
FOR i = 0 to $(var)-1
let sheetName=subfield(peek('NEW', i,'Tables1'),'$',1);
[$(sheetName)]:
Data:
LOAD
ID,
'$(sheetName)' as Flag ,
FROM
Data.xlsx
(ooxml, embedded labels, table is [$(sheetName)]);
NEXT i
DROP Table Tables1;
STORE Data into C:QVD\Data.qvd (qvd);
DROP Table Data;
I have a sheet with name as custom. this is the sheet getting problem. I tried deleting the sheet but appears again .how can I delete this from the script?
Hi Amelia
You can test the sheet name before load. Try something like this:
If Index(sheetName, 'Sheet') > 0 Then
Load
Endif