Skip Ribbon Commands
Skip to main content
Navigate Up
Sign In

Quick Launch

Average Rating:

(1 Rating)
facebook Twitter
Email
Print Bookmark Alert me when this article is updated

Feedback

Batch Script exits after invoking only the first task/taskflow using the RunAJobCli utility in Informatica Cloud
Problem Description
Batch script is configured to invoke multiple task/taskflows in Informatica Cloud using the RunAJobCli utility. However when the batch script is triggered, only the first task/taskflow is invoked. Sample script is mentioned below:

set PATH=E:\Informatica\Cloud Secure Agent\jre\bin;E:\Informatica\Cloud Secure Agent\main\tools\runAJobCli;%PATH% 

cli.bat runAJobCli -n "TF1" -t workflow -w true -d 

IF %ERRORLEVEL% NEQ 0 ( 
exit /b 1 
ELSE 
(cli.bat runAJobCli -n "TF2" -t workflow -w true -d 
IF %ERRORLEVEL% NEQ 0 ( 
exit /b 1 
)) 
exit /b 0 
Cause
​In this scenario, the issue occurs since the control is not passed to the next command in the script after the first command is executed.
Solution
​To resolve the issue, use the CALL command when executing the first task/taskflow. This will ensure that the control is retained until the first command excutes and then passed to the next command in the script. Below is an example:

set PATH=E:\Informatica\Cloud Secure Agent\jre\bin;E:\Informatica\Cloud Secure Agent\main\tools\runAJobCli;%PATH% 

CALL cli.bat runAJobCli -n "TF1" -t workflow -w true -d 

IF %ERRORLEVEL% NEQ 0 ( 
exit /b 1 
ELSE 
(cli.bat runAJobCli -n "TF2" -t workflow -w true -d 
IF %ERRORLEVEL% NEQ 0 ( 
exit /b 1 
)) 
exit /b 0 
More Information
Applies To
Product(s): Cloud Data Integration
Product Version(s):
Database:
Operating System(s):
Other Software:

Reference
Attachments
Last Modified Date:7/10/2018 5:19 AMID:533421
People who viewed this also viewed

Feedback

Did this KB document help you?



What can we do to improve this information (2000 or fewer characters)