Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Concatenating loads from Excel files

All,

Maybe this might have been asked/answered before, but here's the issue I'm having :

Table:

LOAD

.

.

FROM Folder\Name-*.xls

does not seem to concatenate the excel files while I have seen similar code work in concatenating *.qvd files. With the above code, the data goes into a new table for each file.

Any ideas on what/how I could change the code for concatenation? Thanks.

-Sandy.

4 Replies
hector
Specialist
Specialist

Hi, you forgot mention the Sheet on the load statement, is this just an example?

rgds

Not applicable
Author

Yup, this is just an example. In my code I do have the sheet name :



from

[Folder\File.xls] (biff, embedded labels, table is [Summary$]);



Not applicable
Author

are there an identical number of columns, and are they named the same? -- they need to be for QV to auto-concatenate.

Not applicable
Author

Ryan,

Yes they are. I managed to get the concatenation to work by simply using :

FOR EACH file in filelist and then,

placing a CONCATENATE before the LOAD statement

But I find that the data is not loaded into the table (Report) that I specified. Here's the example code :







for

CONCATENATE

LOAD subfield(filebasename(),'.',2) as Date,

'Weekly'

as ReportType,

Description

,

Tdata,

Volume,

NVolume

,

Tdata2

,

Vol2

,

NV2

FROM

[$(File)] (biff, embedded labels, table is [Summary$] );each File in filelist (FolderName&'Report.*.W.xls')

Report:







next

File;