This is a control statement for setting registration information of jobs. When defining a job control statement, ensure that you specify a job net control statement immediately before the job control statement.
Synopsis
Job control statement for job nets with the Job Execution Control attribute
JOB ---------- (1) jobname Job ---------- (2) (*) (Note 1) jobnumber Job number ---------- (3) (*) (Note 2) jobattr Job attribute ---------- (4) (Note 4) jobname_jes Job name in Job Execution Control ---------- (5) (Note 8) masterlinkjobnet Master linked job net name ---------- (6) (Note 17) jobparam Parameter ---------- (7) (Note 8) directory Directory ---------- (8) (Note 8) jobcomment Comment ---------- (9) (Note 8) req_host Request host name ---------- (10) (Note 8) queuename Queue name ---------- (11) (Note 8) normallimit Upper limit of normal completion code ---------- (12) (Note 8) endcodeignore Ignore completion code ---------- (13) (Note 8) nooutput Do not save output ---------- (14) (Note 8) restartpoint Restart point ---------- (15) (Note 5) pre_job Preceding job number ---------- (16) pre_job_endcode Condition concerning completion code of preceding job -------- (17) (Note3)(Note 4) execdaymode Valid only on startup days --- (18) (Note12)(Note13)(Note 14)(Note 15) execuser Execution user name ---------- (19) (Note 8) resource Resource name ---------- (20) (Note 8) resource_attr Resource allocation ---------- (21) (Note 7)(Note 8) stdoutfile Standard output file name ---------- (22) (Note 8) stderrfile Standard error output file name ---------- (23) (Note 8) errtostdfile Output standard error output to standard output file --------- (24) (Note8)(Note10) jobfile_trans Transmission of execution command ---------- (25) (Note 8) priority Execution priority ---------- (26) (Note 8) predictiontime Estimated processing time ---------- (27) (Note 8) limittime Cut-off execution time ---------- (28) (Note 8) netvar_prefix Job net variable prefix ---------- (29) (Note 8) envname Environmental variable name ---------- (30) (Note 8) envvalue Environmental variable value ---------- (31) (Note 8)(Note 9) joblogfile Joblog filename ---------- (32) (Note 11) stepname Start step name ---------- (33) (Note 11) codelaststep Use last executed stop completion code as job completion code ---------- (34) (Note 11) operate Operation ---------- (35) jobicon Icon type ---------- (36) (Note 6) iconposition Icon position ---------- (37) (Note 16) ;
The jobname operand should be specified immediately after the JOB keyword.
The jobnumber operand should be specified immediately after the jobname operand.
To specify the pre_job_encode operand, at least one preceding job number should be specified for
the pre_job operand.
The pre_job_endcode cannot be specified with the jobattr operand simultaneously.
A restart point can be set for only one of the jobs making up a job net.
Specify a value other than "GLJO," "GLBO" or "INTS". [Windows]. Specify a value other than "INTS". [UNIX]
The resource_attr operand should be specified immediately after the resource operand.
This operand cannot be specified if the job net "JNET" or the linked job net "LNET" is specified as the icon type.
The envvalue operand should be specified immediately after the envname operand.
This operand cannot be specified with the stderrfile operand simultaneously.
This operand can be specified only when the Batch framework job "BJOB is specified as the icon type.
This operand can be specified only when the job net "JNET" or the linked job net "LNET" is specified as the icon type.
This operand cannot be specified if "RECOVERYONLY" or "RECOVERYRERUN" is specified with the jobattr operand.
This operand cannot be specified if "ON" is specified with the restartpoint operand.
This operand cannot be specified if any value is specified with the pre_job_endcode operand. Additionally, if the pre_job_endcode operand is specified for a subsequent job, this operand cannot be specified.
This operand must be specified for all jobs that make up the job net.
This operand must be specified when the linked job net "LNET" is specified as the icon type.
This must be specified.
Job control statement for job nets with the Interstage execution attribute
JOB ---------- (1) workunitname Workunit name ---------- (38) (*) (Note 1) jobnumber Job number ---------- (3) (*) (Note 2) systemname System name ---------- (39) jobcomment Comment ---------- (9) req_host Request host name ---------- (10) queuename Queue name ---------- (11) resource Resource name ---------- (20) resource_attr Resource allocation ---------- (21) (Note 4) normallimit Upper limit of normal completion code ---------- (12) endcodeignore Ignore completion code ---------- (13) operate Operation ---------- (35) jobicon Icon type ---------- (36) (*) (Note 3) iconposition Icon position ---------- (37) (Note 5) ;
The workunitname operand should be specified immediately after the JOB key word.
The jobnumber operand should be specified immediately after the workunitname operand.
In this operand, "INTS" must be specified. If an icon type other than "INTS" is specified for the job net having the Interstage attributes or if "INTS" is specified for a job net having the attributes other than Interstage, this command is terminated abnormally.
The resource_attr operand should be specified immediately after the resource operand.
This operand must be specified for all jobs that make up the job net.
This must be specified.
Job control statement for job nets with the PowerAIM execution attribute [UNIX]
JOB ---------- (1) systemname Business system name ---------- (40) (*) (Note 1) workunitname Workunit name ---------- (38) (*) (Note 1) jobnumber Job number ---------- (3) (*) (Note 2) jobattr Job attribute ---------- (4) (Note 4) jobcomment Comment ---------- (9) normallimit Upper limit of normal completion code ---------- (12) endcodeignore Ignore completion code ---------- (13) nooutput Do not save output ---------- (14) restartpoint Restart point ---------- (15) (Note 5) pre_job Preceding job number ---------- (16) pre_job_endcode Condition concerning completion code of preceding job --- (17) (Note 3)(Note 4) operate Operation ---------- (35) jobicon Icon type ---------- (36) iconposition Icon position ---------- (37) (Note 6) ;
The systemname operand and workunitname operand should be specified immediately after the JOB keyword in a row.
The jobnumber operand should be specified immediately after the workunitname operand.
To specify the pre_job_encode operand, at least one preceding job number should be specified for the pre_job operand.
The pre_job_endcode cannot be specified with the jobattr operand simultaneously.
A restart point can only be set for one of the jobs making up a job net.
This operand must be specified for all jobs that make up the job net.
This must be specified.
Job control statement for job nets with the Normal execution attribute [UNIX]
JOB ---------- (1) jobname Job ---------- (2) (*) (Note 1) jobnumber Job number ---------- (3) (*) (Note 2) jobattr Job attribute ---------- (4) (Note 4) directory Directory ---------- (8) jobcomment Comment ---------- (9) normallimit Upper limit of normal completion code ---------- (12) endcodeignore Ignore completion code ---------- (13) nooutput Do not save output ---------- (14) restartpoint Restart point ---------- (15) (Note 5) pre_job Preceding job number ---------- (16) pre_job_endcode Condition concerning completion code of preceding job ----- (17) (Note 3)(Note 4) operate Operation ---------- (35) jobicon Icon type ---------- (36) iconposition Icon position ---------- (37) (Note 6) ;
The jobname operand should be specified immediately after the JOB keyword.
The jobnumber operand should be specified immediately after the jobname operand.
To specify the pre_job_endcode operand, at least one preceding job number is specified for the pre_job operand.
The pre_job_endcode operand cannot be specified in conjunction with the jobattr operand.
A restart point can be specified for only one of the jobs making up a job net.
This operand must be specified for all jobs that make up the job net.
This must be specified.
About This Control Statement
(1) JOB
This is the keyword that indicates the beginning of a job control statement.
(2) jobname Job
The name of the batch program, command or program that will be executed as a job must be no longer than 260 bytes, including the pathname. The file name and parameters together must not exceed 300 bytes in length.
$ `
If a file name specified in a UTF-8 environment (or, in the case of network jobs, an environment where the submitting server or execution server uses UTF-8 encoding) contains Japanese characters, the specified job name cannot include Japanese characters.
If the child job net "JNET" is specified as the icon type, the name of a child job net must be specified.
If the batch framework job "BJOB" is specified as the icon type, specify the batch job definition within 64 bytes using lowercase letters (a-z), uppercase letters (A-Z), numbers (0-9), hyphens (-) and/or underscores (_). Also, the name must start with a lowercase letter (a-z) or uppercase letter (A-Z).
If the linked job net "LNET" is specified as the icon type, specify the job net name of the linked job net within 50 bytes. Ensure that the name does not duplicate the names of other job nets or linked job nets. The following characters cannot be used: /?*;,\"<>|:'., space, or any user-defined character.
Do not specify the qsub command of Job Execution Control or a batch file or shell script that calls the qsub command as a job.
(3) jobnumber Job number
Allocate numbers corresponding to the jobs by using numbers ranging from 1 to 255. Unique numbers should be assigned, according to the order in which the jobs are executed. They should be allocated in ascending order from the preceding to the subsequent jobs.
(4) jobattr Job attribute
Specifies the job as a recovery job. The preceding job numbers must be specified. Also, this operand specifies whether or not to rerun the preceding jobs of the recovery job.
Specifies this job as the recovery job. Even if this recovery job is completed normally, the preceding job is not rerun.
Specifies this job as the recovery job. If this recovery job is completed normally, the preceding job is rerun.
(5) jobname_jes Job name in Job Execution Control
Specify job names within 64 bytes each so that they can be distinguished from each other. Job names are not allowed to contain spaces, any user-defined characters, or the following characters:
/ ? * ; , \ " < > | : ( ) ' . $ `
# cannot be used for the first character.
An ampersand (&) cannot be used for the job name of network jobs and Distributed Execution jobs.
The job name defined here can be also used as the job name used in the Job Execution Control.
If you omit the job name, the string (excluding the path name and extension) specified in jobname is used as jobname_jes. Therefore, if jobname contains Japanese characters in a UTF-8 environment (an environment where the submitting server or execution server for network jobs uses UTF-8 encoding), in this option you must specify a string that does not contain Japanese encoding.
(6) Master linked job net name
If the linked job net "LNET" is specified as the icon type, specify the job net name of the master linked job net specified as the reference of the linked job net.
(7) jobparam Parameter
Specify the character string (parameter) as a command argument with 1024 bytes or less.
If the character string with spaces is specified as one parameter, it must be enclosed in double quotation marks.
If the batch framework job "BJOB" is specified as the icon type, this cannot be specified.
(8) directory Directory
For the job having the Job Execution Control attribute, specify the directory name to which the qsub command of the Job Execution Control is to be executed, with 64 bytes or less. The name should not contain spaces or user-defined characters.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
If the attribute of job is the Normal attribute, specify the directory in which the job is to be executed. [UNIX]
(9) jobcomment Comment
Specify a comment on the job in 64 bytes or less. The comment cannot contain the user-defined characters.
(10) req_host Request host name
Specify the name of the host to which the job is submitted with 64 bytes or less. If omitted, the job is submitted to the default host specified in the job net.
You can use the execution subsystem name with job nets that have the Job Execution Control attribute.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
Specify a second candidate execution server which is used in case the first candidate execution server goes down. The servers should be specified in the form "host name of first candidate, host name of second candidate". A local host name (connection destination host) cannot be specified as the host name of second candidate. In addition, you cannot use the execution subsystem name as the host name of either the first candidate or the second candidate. The synopsis is shown below.
req_host host name of first candidate, host name of second candidate
Note
Cautions when you specify the first candidate and second candidate execution servers
A comma (,) is recognized as a separator used between the first candidate host and the second candidate host. Therefore, a host name should not contain a comma.
The total number of bytes of host name is 64 bytes or less, which includes the host name of first candidate, the host name of second candidate, and a comma.
(11) queuename Queue name
Specify the name of the queue to which the job will be submitted within 15 bytes using alphanumeric characters. If omitted, the job is submitted to default queue.
If the batch framework job "BJOB" is specified as the icon type, specify the job queue name within 15 bytes using lowercase letters (a-z), uppercase letters (A-Z), numbers (0-9), hyphens (-) and/or underscores (_). Also, the name must start with a lowercase letter (a-z) or uppercase letter (A-Z). This operand can be omitted.
(12) normallimit Upper limit of normal completion code
Specify the value to determine whether the job has been completed normally or terminated abnormally.
If the value of the job completion code is "0" or more and less than the value in the upper limit of normal completion code, the job is considered to have completed normally. If the value of the job completion code is greater than the value in the upper limit of normal completion code, the job is considered to have terminated abnormally.
A value between "0" and "255" can be specified. If omitted, the default is "0".
Note that the job status is differentially displayed if the status option [Validate pseudo-normal] is selected in the [Define Jobscheduler Startup Parameters] window. Namely, for the job with completion code 0, the status is displayed as "Normal completion", and for the job with completion code more than 1 and less than the upper limit of normal completion code, the status is displayed as "Pseudo-normal".
(13) endcodeignore Ignore completion code
Specify "ON" to ignore the completion code of the job. Setting "ON" causes the job to be handled as normally completed regardless of the completion code, and the subsequent job is executed.
(14) nooutput Do not save output
Specify "ON" when the standard output/error output is not referenced. Setting "ON" disables saving of the standard output/error output of the job.
If the batch framework "BJOB" is specified as the icon type, and when you do not want to save the standard output/standard error output in a job log file, specify "ON".
(15) restartpoint Restart point
Set "0" with this operand to start from this job when restarting the job net. The restart point can be specified for only one of the jobs making up the job net. Note that it cannot be specified for a recovery job.
(16) pre_job Preceding job number
Specify job numbers of preceding jobs. Use a comma as a separator to specify more than one preceding job number. If specifying many job numbers, specify them in the ascending order as it becomes efficient to check.
To use the "OR" condition to wait for the preceding job to end, first specify "OR," ("OR" followed by a comma) followed by the preceding job number. The following restrictions apply to the "OR," specification:
You cannot specify "OR," for a recovery job.
You cannot specify "OR," for a job whose execution condition is the completion code of the preceding job.
You cannot specify a job other than an event wait job as the preceding job.
You cannot set the specified preceding job as the preceding job of another job.
The jobs specified as preceding jobs must be defined beforehand. If this parameter is omitted, the top of jobs is defaulted.
(17) pre_job_endcode Condition concerning completion code of preceding job
This is specified to narrow down the execution conditions of subsequent jobs, according to the completion code of preceding job. You need to choose the synopsis between two types depending on the conditions "By value" or "By range" that you select.
An error will occur if the specified execution condition is inconsistent with the condition of the preceding job that normally completes. Ensure that the value greater than the one that you will specify is set to the upper limit of normal completion code of the preceding job or "Ignore completion code" is set for the preceding job.
For the conditions "By value":
The synopsis is shown below.
pre_job_encode Judgment operator, comparison value
The following six operators for checking are available: Specify an integer from 0 to 255 as the comparison value that is compared with the preceding job completion code.
Equal to "comparison value"
Not equal to "comparison value"
Greater than "comparison value"
Greater than or equal to "comparison value"
Less than "comparison value"
Less than or equal to "comparison value"
For the conditions "By range":
The synopsis is shown below.
pre_job_encode Judgment operator 1, Comparison value 1, Judgment operator 2, Comparison value 2
Specify an integer between 0 and 255 for "Comparison value 1" and "Comparison value 2", and specify a value smaller than "Comparison value 2" for "Comparison value 1".
Specify one of the following to "Judgment operator 1."
Greater than "comparison value 1"
Equal to or greater than "comparison value 1"
Specify one of the following to "Judgment operator 2".
Smaller than "comparison value 2"
Equal to or smaller than "comparison value 2"
(18) execdaymode Valid only on startup days
Specify this option if you want the job (job net) to start only if the specified message is generated on a selected startup days. To do so, specify "ON" with the "Valid only on startup days". If omitted, "Valid only on startup days" is not set.
Specifies "Valid only on startup days".
(19) execuser Execution user name
Specify the name of the user who will execute the job, within 64 bytes.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(20) resource Resource name
Specify the name of resource to be used within 64 bytes. English alphanumeric characters, "_" (under bar) and "-" (hyphen) are available. If omitted, resources will not be allocated. If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(21) resource_attr Resource allocation
Specify how to allocate the specified resource (SH: shared use, EX: exclusive use). If omitted, the default is SH.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(22) stdoutfile Standard output file name
Specify the name of the file to which standard output for the job is output, in a full path name within 256 bytes.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(23) stderrfile Standard error output file name
Specify a full path name to the file to which standard error output is output, within 256 bytes.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(24) errtostdfile Output standard error output to standard output file
Specify "ON" when outputting the job standard error output to standard output file.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(25) jobfile_trans Transmission of execution command
Specify "ON" when you transfer the execution file to be started as the job to the Request host. If omitted, the execution file existing on the Request host is executed.
If the batch framework job "BJOB" is specified as the icon type, this operand cannot be specified.
(26) priority Execution priority
If the connection destination is the server based on Window version, specify the execution priority of the jobs between 4 (the highest priority) and 0 (the lowest priority).
If the connection destination is the server based on UNIX version, specify the execution priority of the jobs between 39 (the highest priority) and 0 (the lowest priority).
If omitted, the default is priority 0.
If the batch framework job "BJOB" is specified as the icon type, specify the execution priority in job queue using range from 63 (the highest priority) and 0 (the lowest priority). This can be omitted. If omitted, the default is 32.
(27) predictiontime Estimated processing time
Specify an estimated elapsed time for the job. This value can be specified between 1 and 35791394 (minutes). If omitted, no estimated elapsed time is set.
This operand is valid only for the job within a job net with the "Job Execution Control" attribute.
(28) limittime Cut-off execution time
Specify a value between 1 and 1666666 in minutes to limit the processing time of the job.
Make sure to specify the value larger than the one specified as the estimated processing time.
(29) netvar_prefix Job net variable prefix
To import the "NAME=VALUE" format line from the previous log into the job net variable, specify a job net variable prefix up to 13 bytes.
Only alphanumeric characters can be used. If this operand is omitted, the format line is not imported into the job net variable.
(30) envname Environmental variable name
Specify the name of the environmental variable when you specify the environmental variable at job execution. Specify it within 64 bytes using only alphanumeric characters and underscore (_).
If the batch framework job "BJOB" is specified as the icon type, specify the replaceable parameters in the batch job definition within 64 bytes using lowercase letters (a-z), uppercase letters (A-Z), numbers (0-9), hyphens (-) and/or underscores (_). Also, the name must start with a lowercase letter (a-z) or uppercase letter (A-Z).
Up to 32 environmental variable names can be specified.
(31) envvalue Environmental variable value
Specify the value of the environment variable name that is specified with the envname operand immediately before this operand with up to 256 bytes. The value cannot contain user-defined characters.
If the batch framework job "BJOB" is specified as the icon type, specify the replaceable parameters in the batch job definitions with up to 256 bytes. The value cannot contain user-defined characters.
Example of environmental variable specification
[Windows]
envname TEMP_PATH envvalue d:\temp envname DATA_PATH envvalue d:\work1\data
[UNIX]
envname LD_LIBRARY_PATH envvalue /usr/openwin/lib envname OPENWINHOME envvalue /usr/openwin
(32) joblogfile Joblog filename
Specify a job log file name in a full path name within 256 bytes.
The name cannot contain spaces or user-defined characters.
(33) stepname Start step name
Specify the Start step name with 64 bytes or less using lowercase letters (a-z), uppercase letters (A-Z), numbers (0-9), hyphens (-) and/or underscores (_). Also, the name must start with a lowercase letter (a-z) or uppercase letter (A-Z). This operand can be omitted.
(34) codelaststep Use last executed step completion code as job completion code
Use this option when you want to use the completion code of the last-executed job step as the job completion code. To do so, specify "ON". If omitted, the completion code of the last-executed job step does not become the job completion code.
If this option is omitted, the completion code of this job becomes the completion code defined in the batch framework job (either the maximum completion code or the completion code of the last executed job).
(35) operate Operation
Indicates the status resulting from the operation as either paused or disabled. The default value is "NONE".
Paused
Disabled
When job information is registered or changed, the status of the job will be "Waiting".
(36) jobicon Icon type
Specify an icon type to be added by using parameters. The correspondence between icon types and parameters are shown in the table below. And an example of synopsis is described later in this article. If this operand is omitted, the default is Execute command "CMND". For a job with the Interstage attribute, this operand cannot be omitted.
Icon type | Parameter |
---|---|
Execute command | CMND |
Send message | MESG |
Start service | SSTR |
Stop service | SEND |
File wait | FWAT |
Backup cooperation | BKUP |
Application execution (client) | EXAC |
Application execution (server) | EXAS |
File compression/expansion (client) | FPRC |
File compression/expansion (server) | FPRS |
File control (client) | FCLC |
File control (server) | FCLS |
File transfer (client) | FCPC |
File transfer (server) | FCPS |
Power on (client) | PONC |
Shutdown (client) | POFC |
Remote access control | RASC |
Interstage | INTS |
Batch framework job | BJOB |
Remote access control (Connect) | RASS |
Remote access control (Disconnect) | RASE |
Rename file (client) | RNFC |
Rename file (server) | RNFS |
Delete file (client) | DLFC |
Delete file (server) | DLFS |
Create directory (client) | MKDC |
Create directory (server) | MKDS |
Delete directory (client) | RMDC |
Delete directory (server) | RMDS |
Check log file | CHKL |
Wait for time | WATT |
Check service status | CHKS |
Job net | JNET |
Linked job net | LNET |
Wait for message event | CMSG |
Wait until specified time | SLEP |
Check file existence | JGFL |
Check job net variable | JGVR |
User definition 1 (to user definition 100) | U001 (to U100) |
Statement Example
jobicon CMND
(37) iconposition Icon position
This option specifies position information for the job icon using the following format. The numbers indicate the coordinates for the grid position, taking the top left corner of the job flow as the origin (1,1).
Horizontal position (1 to 255), vertical position (1 to 255)
If this option is omitted, the position of the icon will be determined automatically. If the icon position is changed using the Change Group window after the job has been registered without specifying this option, the new icon position will be stored, and this control statement will be output using the jobschprint -r command.
(38) workunitname Workunit name
Specify the job (workunit name) to be requested to Interstage for execution, with 36 bytes or less.
(39) systemname System name
Specify the system name within 8 bytes.
(40) systemname Business system name [UNIX]
Specify the business system name as the request destination within 7 bytes.
Example of Job Control Statement
The following provides a sample control statement when a job net has the job configuration as shown below:
NET jobnetname MANAGEMENT jobnetcomment BusinessManagement starttime 0850 execpattern 20thEveryMonth holidaycalendar SYSTEM_CALENDAR <- SYSTEM_CALENDAR is used as the calendar. holidayshift BEF job 5 ; JOB jobname WORK1.bat jobnumber 1 ; JOB jobname WORK2.bat <- Definition of WORK2 job jobnumber 2 <- Job number of WORK2 pre_job 1 <- Job number of the preceding job of WORK2 ; (Preceding job number 1 is already defined as WORK1) JOB jobname WORK3.bat jobnumber 3 pre_job 2 ; JOB jobname WORK4.bat jobnumber 4 pre_job 1 ; JOB jobname WORK5.bat jobnumber 5 pre_job 4 ;