Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I have an error using batch mode to reload a document.
I tried to run this command:
C:\Program Files\QlikView\Distribution Service\QVDistributionService.exe -r=D:\test.qvw
And have this output log:
16/02/2012 11:23:43 Information Setting RunLevel to Batch
16/02/2012 11:23:43 Information Allocating QlikView Engine
16/02/2012 11:23:43 Information Allocating new QlikView Engine. Current usagecount=1 of 1
16/02/2012 11:23:43 Information An instance of the QlikView Engine is being created
16/02/2012 11:23:43 Information Starting QlikView Engine
16/02/2012 11:23:43 Information Allocated QlikView Engine successfully. Current usagecount=1 of 1, Ticket=1
16/02/2012 11:23:43 Information Loading document "D:\test.qvw" (3.52 Mb)
16/02/2012 11:23:44 Information Loading. LoadTime=00:00:01.0139935
16/02/2012 11:23:46 Information Loading. LoadTime=00:00:03.0419805
16/02/2012 11:23:47 Information Physical FileSize=3.52 Mb. Memory Allocation Delta for this file=27.16 Mb. Available Physical Memory Before Open=2122.70 Mb. Available Physical Memory After Open=2104.04 Mb. Total Physical Memory=3895.07 Mb.
16/02/2012 11:23:47 Information The document was loaded successfully.
16/02/2012 11:23:47 Information Initializing Checkout (0), Loading document (546), Initializing load (561), Checking read (561), Creating QlikView Engine (561), Checking Size (593), Load (2621), Load Completed (2964), Tables read (4165), Opened successfully (4227)
16/02/2012 11:23:47 Information Document was opened successfully
16/02/2012 11:23:47 Information Opened successfully (0)
16/02/2012 11:23:47 Information QlikView->Settings->Document Peferences->Generate Logfile in document is not set.
16/02/2012 11:23:49 Information The Source Document is being reloaded. DocumentPath=D:\test.qvw
16/02/2012 11:23:49 Information The Source Document reload complete. DocumentPath=D:\test.qvw
16/02/2012 11:23:49 Information Memory Allocation Delta for this file=-10.55 Mb. Available Physical Memory Before Reload=2103.84 Mb. Available Physical Memory After Reload=2108.02 Mb. Total Physical Memory=2108.02 Mb.
16/02/2012 11:23:50 Error The Source Document was NOT reloaded successfully. DocumentPath=D:\test.qvw.
16/02/2012 11:23:50 Information Initializing Reload (0), Finished (2589)
16/02/2012 11:23:50 Information Closing the document.
16/02/2012 11:23:50 Information Closed the QlikView Engine successfully. ProcessID=1908
16/02/2012 11:23:50 Information Initializing (0), Finished (328)
16/02/2012 11:23:50 Error The Batch Job failed. ErrorCount=1
16/02/2012 11:23:50 Information Setting exit code to the number of errors. ErrorCount=2
I tried with an easier document and the command runs normally. Manual reload works very well too.
Thank you.
Hello,
That’s an interesting one as there is a line saying
16/02/2012 11:23:49 Information TheSource Document reload complete. DocumentPath=D:\test.qvw
You say Manual reload works ok, is this when you run the reload from theDeveloper application?
It is likely to be something in the script or security.
When you open the document in the developer, goto the settings menu,document properties and tick the Generate Logfile option.
Re-run the batch job and have a look at the D:\test.qvw.log file that hasbeen created, it should show which part of the script has failed.
Alternatively it could be security, does the batch command use your usernameor is there a QlikView Service username that has been created? it could be thatthe username doesn’t have permission to open the database/file if one is beingused.
Done & fixed! It was a problem of permissions to the DB
Thank you.
...now the problem is: I can set a variable and its value from command line. How can I invoke this variable into the script??
Thank you.
I'm not sure how you would pass a variable with the command line
BUT you could use the include() statement in your script to load a section of qlikview script code directly from a file.
$(Include=abc.txt);
where you edit the abc.txt as needed and it could say
let my_var=123;
I am using this command line:
C:\Program Files\QlikView\Distribution Service\QVDistributionService.exe -r=D:\test.qvw
and am adding just a parameter per variable, as I've read the guide.
C:\Program Files\QlikView\Distribution Service\QVDistributionService.exe -r=D:\test.qvw -vTest=2
This is to integrate a web application with qv document in server environment. The web application is a PHP CMS and I can use exec function to call the command line and send the first filter to qv document. The document will be (partial) reloaded.
I don't think I can use files in this case.