Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
QlikviewRaj11
Contributor III
Contributor III

load multiple .xlsx files in a folder in SharePoint...

Hi , could someone please help with the below..

I have a share point with folders like DEV, QA, UAT, PRD these are sub folders under a folder called REPORTS

I am trying to load all of the .xlsx files into 1 single table ... in Qlikview. 

FactTemp:
Load  ''  as Temp AutoGenerate 0;

https://sp.mycompany.net/sites2/spqtfssvvl/StoreTrust%20Management/BCCI/Reports%20-%20BCI%20-%20DEV]

This is how my SP URL looks like if I copy and paste into my inranet it shows me all of the .xlsx files in DEV folder


Set vDirectory =[https://-------- 20DEV/];

sub ScanFolder($(vDirectory))

for each FileExtension in 'xlsx'

for each FoundFile in filelist( Root & '/*.' & FileExtension)

Concatenate (FactTemp)

LOAD *

FROM [$(FoundFile)] (ooxml, embedded labels, table is [DT]);

next FoundFile

next FileExtension

for each SubDirectory in dirlist( $(vDirectory) & '/*' )

call ScanFolder(SubDirectory)

next SubDirectory

end sub;

Syntax error

Unexpected token: ':', expected one of: ',', ')'

sub ScanFolder(https>>>>>>:<<<<<<//sp.mycompany.net/sites2/spqtfssvvl/StoreTrust%20Management/BCCI/Reports%20-%20BCI%20-%20DEV)

 

There is something wrong in this.. could someone help ...I also need to adjust the file name in the FROM Clause

 

3 Replies
QlikviewRaj11
Contributor III
Contributor III
Author

Anyone used the Qlikview to read the .xlsx files from a sharepoint folder

I have folders like DEV,QA,PRD - Each folder has few excel files - I cannot  use the path/*.xlsx from sharepoint

how do I get the list of excel file names  into a table and pass each file name into the FROM clause

tried something from other but I get the FileText is not a field error - any help

Brett_Bleess
Former Employee
Former Employee

You can have a look at the Office365 SharePoint connector, but that one does require a license, just FYI.  The Help on this does not recommend looping etc. due to API limitations, so wondering if that may be what you are running into here:

https://help.qlik.com/en-US/connectors/Subsystems/Web_Connectors_help/Content/Connectors_QWC/Data-So...

Best I have, might want to do some searching on the SharePoint forums to see if you can find something there, as I would suspect this is more a SharePoint issue than a QlikView issue in this case.

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.
Brett_Bleess
Former Employee
Former Employee

See duplicate post: https://community.qlik.com/t5/QlikView-App-Development/can-someone-hlep-on-figureing-out-how-this-is...

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.