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: 
Not applicable

how to upload 2 excel files at a time

Hi frnds,

i have 2 excel files in which it has 2 sheets each....

i want to load both of them at a tym.

in 1st excel file

1st sheet is

d sheet is

In 2nd excel seet we have

1st & 2nd sheet is

i want to load both the excel files using for loop?Plzzzzzzzzzzzzzzzzz helpppppppppppppppppppppppp

write the scripting code plssssss

14 Replies
t_moutault
Contributor III
Contributor III

Hi,

take a look at this :

// SUBPROGRAM : all xls files in repository

SUB ListeEnquetes(Root)

  //Récupération des fichiers enquête

  FOR Each File in filelist (Root&'\TEST*.xls' )

       IF FileSize('$(File)') > 0 then

            Enquêtes:

            LOAD

               *

            FROM

            [$(File)]

            (biff, embedded labels, table is Feuil2$);

       ENDIF

  NEXT File

ENDSUB

//Exécution du sous programme

CALL ListeEnquetes ('\\SRV\TEST')

Not applicable
Author

can u pls post the reply in English

oknotsen
Master III
Master III

The code is in English and perfectly understandable. The only thing not in English are the name of the SUB and the name of the table; they will work perfectly even when not in English.

Just copy-paste it and replace the none-code words by the names of your files, sheets and (table and sub) naming convention .

If you have any specific questions left, please let us know.

If not, please flag the topic as answered.

May you live in interesting times!
Not applicable
Author

Hi,

I got another method , can you see this attached files.

Untitled.png

Not applicable
Author

  • With that approach ,we will get one sheet at atime.......
  • i want all the sheets in both two excel sheets
Not applicable
Author

1st excel file name is :Excel1

               in that the sheet names are  Sheet1 and Sheet2

2nd excel file name is : Excel2

                    in this file,the sheets are Sheet1 and Sheet2

Im new to qlik view....

Please write the exact code and i will copy paste

and i will run......

Waiting for the reply

oknotsen
Master III
Master III

Assuming the sheets have the same columns (which don't even have to be in the same order), the different sheets will automatically concatenate.

Did you try it?

May you live in interesting times!
Not applicable
Author

i know for

how to load multipe excel sheets from a single file

for loop.jpg

But my question is

How to load 2 excel files which has 2 sheets ezch

for the above scenario?

krishna20
Specialist II
Specialist II

Hi,

Please follow this link.hope it helps

Load Multiple excel sheets using For loop