Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
tamilarasu
Champion
Champion

Loading XLSB file format into Qlikview

glitter-hello-text-smiley-emoticon.gif


                We have multiple xlsb format files and I want to load all of them in a single table. I have created ODBC connection but I can not find similar thread on how to load multiple files in single table.


Kaushik.solanki‌  I just see your threads regarding the xlsb format issue. Do you have any idea about this.?


Thank you in advance.


22 Replies
jagan
Luminary Alumni
Luminary Alumni

Hi Tamil,

I do not have a XLSB file can you attach a sample file.

Regards,

Jagan.

jagan
Luminary Alumni
Luminary Alumni

Hi,

Can you attach the script you are using to load single xlsb file, I will update the code with loop.

Regards,

Jagan.

tamilarasu
Champion
Champion
Author

Jagan,

Attached some sample files.

Code:

ODBC CONNECT32 TO [Excel Files;DBQ=C:\Users\Tamilarasu.Nagaraj\Desktop\New folder (3)\1.xlsb];

Table:

SQL SELECT *

FROM `C:\Users\Tamilarasu.Nagaraj\Desktop\New folder (3)\1.xlsb`.`'Sheet1$'`;

 

Need to create a ODBC connection.

Kindly have a look. Thank you.

jagan
Luminary Alumni
Luminary Alumni

Hi,

I asked you to attach the code for loading single XLSB file, so that I will update the code with the For loop.

Regards,

Jagan.

tamilarasu
Champion
Champion
Author

Please check now.

jagan
Luminary Alumni
Luminary Alumni

Hi,

Try this script

//to read each file from the specified folder

FOR EACH file in FileList('C:\Users\Tamilarasu.Nagaraj\Desktop\New folder (3)\*.xlsb');

//In order to get the file information from SQLtables command making use of the ODBC connection format

ODBC CONNECT32 TO [Excel Files;DBQ=$(file)];

Table:

SELECT *

FROM '$(file)'.'Sheet1$';

Next

Regards,

jagan.

jagan
Luminary Alumni
Luminary Alumni

HI,

If you got the answer close this thread by giving Correct Answer to the post which helps you in getting answer.

Regards,

jagan.

tamilarasu
Champion
Champion
Author

Jagan,

       I was just checking my old threads and closing some of them. The solution which you have provided was really helpful but it did not read any xlsb files. I found an alternate solution and implemented the same in my application (Long back).

jagan
Luminary Alumni
Luminary Alumni

Tell how you solve this and mark your post as Correct Answer, so that it will be really helpful for people who are looking for this type of solution.

Regards,

Jagan.

tamilarasu
Champion
Champion
Author

I have lots of qvw files in my system and I don't know the correct one. Anyways, I just did a check of your code and found this is working (And marked your answer as correct too).

For Each vFile in Filelist('$(vFolder)*.xlsb')

ODBC CONNECT32 TO [Excel Files;DBQ=$(vFolder)\vFile.xlsb];

Consolidated:

SQL SELECT *

FROM `$(vFile)`.`Sheet1$`;

Next