Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
rajareddyjkl
Contributor III
Contributor III

Qvd

I have 3 excle files
Names
Data 1
Data 2
Data 3
In each excle sheet 10 spread sheets.
Spread sheets name's like
BL -market
BL-loction

In data 1 , data 2 and data 3
Same spread sheets name's

But data 1 ,data 2 and data 3
Few failed name same
Few or different

I want convart into single qvd with Dynamically
in future spread add sheets

Labels (1)
3 Replies
ramasaisaksoft

Hi Raja Reddy,

 

The script below loads the data into qlikview file for multiple sheets in a single load by using the Loop statements. 

 

LET vStartSheetNumber = 1;

LET vEndSheetNumber = 50;

LET vExcelFileName = 'Data';

 

// Generate Empty table

Data:

LOAD

          '' AS Data.Field1,

  '' AS Data.Field2

AutoGenerate(0);

 

 

FOR index = vStartSheetNumber TO vEndSheetNumber

     Concatenate(Data)

     LOAD

          *

     FROM [$(vExcelFileName).xlsx]

     (ooxml, embedded labels, header is 10 lines, table is [Page $(index)]);

NEXT

 

 

Note : in my excel file the sheet names are in the patter of Page 1, Page 2, ..... Page n.

rajareddyjkl
Contributor III
Contributor III
Author

In my case sheet name's like 

BL - market
BL-  loction