Start task at a specified time.
START >>-START--TRANSID(name)-----------------------------------------> .-INTERVAL(0)------------------------. >--+------------------------------------+--+-------------+------> +-INTERVAL(hhmmss)-------------------+ '-REQID(name)-' +-TIME(hhmmss)-----------------------+ | .-------------------------. | | V | | +-AFTER----+-HOURS(data-value)---+-+-+ | +-MINUTES(data-value)-+ | | '-SECONDS(data-value)-' | | .-------------------------. | | V | | '-AT----+-HOURS(data-value)---+-+----' +-MINUTES(data-value)-+ '-SECONDS(data-value)-' >--+----------------------------------------------+-------------> '-FROM(data-area)--LENGTH(data-value)--+-----+-' '-FMH-' >--+--------------------+--+-------------------+----------------> +-TERMID(name)-------+ '-SYSID(systemname)-' '-USERID(data-value)-' >--+----------------+--+---------------+--+-------------+-------> '-RTRANSID(name)-' '-RTERMID(name)-' '-QUEUE(name)-' >--+---------+--+---------+------------------------------------>< '-NOCHECK-' '-PROTECT-'
Conditions: INVREQ, IOERR, ISCINVREQ, LENGERR, NOTAUTH, RESUNAVAIL, SYSIDERR, TERMIDERR, TRANSIDERR, USERIDERR
Note for dynamic transaction routing: Using START if later CANCELed by another task, or if the started transaction uses RETRIEVE WAIT, could create inter-transaction affinities that adversely affect the use of dynamic transaction routing. See the CICS® Application Programming Guide for more information about transaction affinities.
START starts a task, on a local or remote system, at a specified time. The time is specified by INTERVAL, AFTER, AT or TIME. See the section about expiration times in the CICS Application Programming Guide.
The starting task may pass data to the started task. The starting task may also specify a terminal to be used by the started task as its principal facility.
The default is INTERVAL(0), but for C the default is AFTER HOURS(0) MINUTES(0) SECONDS(0).
Note that CEDF is an exception to the START command and is not valid as a TRANSID name. You should therefore not attempt to start CEDF in this way.
You can use the RTRANSID, RTERMID, and QUEUE options to pass further data to the started task. These options can contain arbitrary data values whose meanings depend on what you have specified in the started and starting tasks. One possible way of using them is in the following situation. One task can start a second task, passing it a transaction name and a terminal name to be used when the second task starts a third task. The first task may also pass the name of a queue to be accessed by the second task.
Execution of a START command naming a transaction in the local system cancels any outstanding POST commands executed by the starting task.
START commands can be queued by specifying the LOCALQ option on the RDO TRANSACTION resource definition, as described in the CICS Resource Definition Guide.
If data is to be passed by interval control (using the FROM option), it is queued on a temporary storage queue. The REQID option allows you to specify the name of the temporary storage queue to be used. This identifier may be recoverable (in temporary storage terms) or nonrecoverable. The CICS Resource Definition Guide describes how to define recoverable temporary storage queues.
If you also specify the PROTECT option, the temporary storage queue identified by the REQID option should be defined as recoverable. If you do not specify the PROTECT option, the temporary storage queue should not be defined as recoverable. Unpredictable results can occur if these rules are not followed (see the CICS Recovery and Restart Guide).
If you specify the FROM and not the REQID option, a default 'DF' prefix temporary storage queue is used. The same rules apply as above; only specify the PROTECT option if you define the 'DF' prefix temporary storage queues as recoverable.
This is also true if more than one START command with the same REQID is issued by a task or tasks in the same CICS system. This is due to a tightening of the rules governing the use of the REQID option for start requests that have associated data. In CICS/ESA 4.1, and earlier releases, if you specify the same REQID on more than one START command, in some circumstances CICS accepts the start request. However, this can cause the behavior of subsequent RETRIEVE or CANCEL requests to be unpredictable. In particular, the association between each START and its data is lost. CICS TS regions always reject with an IOERR any START commands that specify a duplicate REQID.
Started tasks without data run without a facility address. Started tasks with data run with a facility address of an ICE until the data is retrieved.
The NOCHECK option specifies that no response (to execution of the START command) is expected by the starting transaction. For START commands naming tasks to be started on a local system, error conditions are returned; error conditions are not returned for tasks to be started on a remote system. The NOCHECK option allows CICS to improve performance when the START command has to be shipped to a remote system; it is also a prerequisite if the shipping of the START command is queued pending the establishing of links to the remote system.
EXEC CICS START
TRANSID('TRNL')
INTERVAL(10000)
REQID('NONGL')
⋮
EXEC CICS START
TRANSID('TRNL')
AFTER HOURS(1)
REQID('NONGL')
⋮
Only one task is started if several START commands, each specifying the same transaction and terminal, expire at the same time or before the terminal is available.
EXEC CICS START
TRANSID('TRN1')
TIME(185000)
TERMID('STA5')
⋮
EXEC CICS START
TRANSID('TRN1')
AT HOURS(18) MINUTES(50)
TERMID('STA5')
⋮
Data is passed to a started task if one or more of the FROM, RTRANSID, RTERMID, and QUEUE options is specified. Such data is accessed by the started task by using a RETRIEVE command.
It is possible to pass many data records to a new task by issuing several START commands, each specifying the same transaction and terminal.
Execution of the first START command ultimately causes the new task to be started and allows it to retrieve the data specified on the command. The new task is also able to retrieve data specified on subsequently executed START commands that expire before the new task is terminated. If the transaction has been defined as restartable (by defining the transaction using the RDO option RESTART(YES)) and such data has not been retrieved before the new task is terminated, another new task is started and is able to retrieve the outstanding data.
If the transaction abends and
has not been
defined as restartable, no new task is initiated and the data is discarded.
EXEC CICS START
TRANSID('TRN2')
TIME(173000)
TERMID('STA3')
REQID(DATAREC)
FROM(DATAFLD)
LENGTH(100)
⋮
EXEC CICS START
TRANSID('TRN2')
AT HOURS(17) MINUTES(30)
TERMID('STA3')
REQID(DATAREC)
FROM(DATAFLD)
LENGTH(100)
⋮
When using the C language, you are recommended to use the AFTER/AT HOURS, MINUTES, and SECONDS options as C does not provide a packed decimal data type. You may use INTERVAL or TIME, but if the value specified is not an integer constant, the application is responsible for ensuring that the value passed to CICS is in packed decimal format.
Some transactions started by a subset of START commands can be dynamically routed to a remote region. For general information about dynamic transaction routing, and specific information about which transactions started by START commands are eligible for dynamic routing, see the CICS Intercommunication Guide.
These exposures result from the delay between the execution of the START and the time of task creation. Even when the START is immediate, CICS may delay creating the task, either because the required terminal is not free or because of other system constraints.
You can use INQUIRE commands to ensure that the transaction and program are enabled at the time of the START command, but either may become disabled before task creation.
You get a TERMIDERR condition if the requested terminal does not exist at the time of the START, but if it is deleted subsequently, as occurs if the user logs off, your START request is discarded with the terminal definition.
If you are also specifying REQID, make sure that the name of the REQID and the name of the QUEUE are not the same.
If this option is omitted, CICS generates a unique request identifier in the EIBREQID field of the EXEC interface block, unless the NOCHECK option is specified, in which case field EIBREQID is set to nulls and cannot be used subsequently to cancel the START command.
If you include any of the data options (FROM, RTERMID, RTRANSID or QUEUE), the data is stored in a TS queue using the REQID name specified (or CICS generated) as the identifier. The queue record thus identified must be local to the CICS system where the START command is processed. The START command is processed on the system identified by the SYSID option or, if the SYSID option is omitted, on the system associated with the TRANSID option.
When retrieved, the value may be used in the TERMID option of a subsequent START command.
When retrieved, the value may be used in the TRANSID option of a subsequent START command.
The terminal identifier must be defined as either a local or a remote terminal on the system in which the START command is executed, when the start of the transaction takes effect.
When using the C language, you are recommended to use the AFTER/AT HOURS, MINUTES, and SECONDS options as C does not provide a packed decimal data type. You may use TIME, but if the value specified is not an integer constant, the application is responsible for ensuring that the value passed to CICS is in packed decimal format.
If SYSID is specified, and names a remote system, the transaction is assumed to be on that system irrespective of whether or not the transaction definition is defined as remote in the PCT. Otherwise the transaction definition is used to find out whether the transaction is on a local or a remote system.
If you omit both TERMID and USERID, CICS uses instead the userid under which the transaction that issues the START command is running. This is referred to as userid2.
By using either userid1 or userid2 CICS ensures that a started transaction always runs under a valid userid, which must be authorized to all the resources referenced by the started transaction.
CICS performs a surrogate security check against userid2 to verify that this user is authorized to userid1. If userid2 is not authorized, CICS returns a NOTAUTH condition. The surrogate check is not done here if USERID is omitted.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.
The security access capabilities of the transaction that issued the command do not allow the command to be performed with the value specified in the USERID option. The security access capabilities of the transaction have been established by the external security manager according to user security, and whether link security or the execution diagnostic facility (EDF) have been in use.
Default action: terminate the task abnormally.
RESUNAVAIL is returned on the EXEC CICS START command executed by the mirror in the target region, if an XICERES global user exit program indicates that a required resource is unavailable on the target region. It is not returned to the application.
Default action: reinvoke the distributed routing program for route selection failure.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.
Default action: terminate the task abnormally.