Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
pjn123pjn123
Contributor III
Contributor III

Loading file with a "(" or ")" in its file name - Error

My script is loading all the xls files in a folder but I get the following error as soon as one of these files have a "(" or ")" in the filename:

"File Not Found".

Am I doing something wrong or is this a limitation of QlikView?

Thanks in advance!

let path_Alles = 'C:\XXXX\*.xls';

for each File in filelist (path_Alles)

AllData:

LOAD SubField('#'&Replace([Policy No],' ',''),'.',1) as Policy,

     Insured as Client,

     'YYYY' as Provider 

FROM

  $(File)

  (biff, embedded labels)

  Where Len(Trim([Policy No])) > 2;

next File

1 Solution

Accepted Solutions
swuehl
MVP
MVP

What about

...

FROM 

[$(File)]

  (biff, embedded labels) 

  Where Len(Trim([Policy No])) > 2

View solution in original post

7 Replies
vinieme12
Champion III
Champion III

try like below

  1. let path_Alles = '[C:\XXXX\*.xls]'
  2.  
  3.  
Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
pjn123pjn123
Contributor III
Contributor III
Author

Hi Veneeth

Thanks for the reply.

Unfortunately, if I change that line nothing gets loaded (loads of errors). 

Anil_Babu_Samineni

May be change as SET instead of LET

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
pjn123pjn123
Contributor III
Contributor III
Author

Hi Anil

Tried it with a SET with and without the [ ] but I get the same result as before.

Anil_Babu_Samineni

Can you show the image for $(File) in text object

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
swuehl
MVP
MVP

What about

...

FROM 

[$(File)]

  (biff, embedded labels) 

  Where Len(Trim([Policy No])) > 2

pjn123pjn123
Contributor III
Contributor III
Author

Thanks Stefan - Work like a charm!

Was almost looking for batch renaming software!

Cheers