Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
gardan
Contributor III
Contributor III

command line and /v switch

I have a mess of xml files all with different names but same structure i need to load into Qlikview. I have a nice vbscript that searches a directory for xml files and passes the name of each file into Qlikview via the /v command line switch. Below is an example of a command line i'm trying to use.

"C:\Program Files\Qlikview 9.0\QV.EXE" /r /vXML_Table=L-0-1264676681640-5326.xml "C:\My Documents\Qlikview\LEAN.qvw"

Unfortunatly, it is not working. Qlikview opens and runs like usual, but variable XML_Table is not getting any value. The below LET statement is where I'm trying to pick up the variable the command line is passing:

LET vXML = $(XML_Table);

But as you can see from the log file excerpt below, vXML is not getting passed anything.

02/23/10 07:27:39: Execution started.
02/23/10 07:27:39: QlikView Version:9.00.7436.8
02/23/10 07:27:39: 0002 LET vLean = 'C:\My Documents\Lean\QVD'
02/23/10 07:27:39: 0004 LET vLeanXML = 'C:\My Documents\Lean\L-0-1264676681640-5326.xml'
02/23/10 07:27:39: 0006 LET vXML =
02/23/10 07:27:39: 0008 ShippingStatusRecord:
02/23/10 07:27:39: 0009 LOAD
02/23/10 07:27:39: 0010 ShippingStatusID,

Any one have any ideas where I'm going wrong?

1 Solution

Accepted Solutions
Not applicable

Try *.xml in the FROM line.

Chris

View solution in original post

4 Replies
Not applicable

Shouldnt you be using SET rather than LET (LET tries to evaluate the expression)?

Why can you not use the contents of the variable XML_TABLE directly anyway?

Regards,

Gordon

Not applicable

Forgot to mention...

If you want to process a folder contents for a certain type of file extension(s) within the script you can do so using a 'FOR EACH...NEXT' loop - have a look at the help.

Regards,

Gordon

Not applicable

Try *.xml in the FROM line.

Chris

gardan
Contributor III
Contributor III
Author

wow, that is slicker than snot on a doorknob!

*.xml loaded up all 43 files one after the other and concatenated them. Thanks!