The TYPE=INIT macro allows you to define the information required for CICS® to
establish its first connection to DB2® and to specify the default options for
other types of the macro.

>>-DSNCRCT--TYPE=INIT--+--------------------+------------------->
| .-HIGH-. |
'-,DPMODI=--+------+-'
+-EQ---+
'-LOW--'
>--+------------------------------+--+----------------------+--->
'-,ERRDEST=(dest1,dest2,dest3)-' | .-AEY9--. |
'-,PCTEROP=--+-------+-'
+-N906D-+
'-N906--'
>--+------------------+--+----------------------------+--------->
'-,PLANI=plan-name-' '-,PLNPGMI=default-exit-name-'
>--+-------------------------+--+-----------------------+------->
'-,PURGEC=minutes,seconds-' '-,RDONAME=DB2CONN-name-'
>--+------------------+--+----------------------+--------------->
| .-YES-. | '-,SHDDEST=destination-'
'-,ROLBI=--+-----+-'
'-NO--'
>--+--------------------------+--+------------------------+----->
'-,SIGNID=authorization-id-' | .-ABEND---. |
'-,STANDBY=--+---------+-'
'-SQLCODE-'
>--+-------------------+--+---------------+--+------------+----->
| .-YES--. | '-,SUBID=db2-id-' '-,SUFFIX=xx-'
'-,STRWT=--+------+-'
+-NO---+
'-AUTO-'
>--+------------------+--+-------------------+------------------>
'-,THRDMAX=integer-' | .-NO--. |
'-,TOKENI=--+-----+-'
'-YES-'
>--+-------------------+--+--------------------+---------------><
| .-YES-. | | .-YES--. |
'-,TXIDSO=--+-----+-' '-,TWAITI=--+------+-'
'-NO--' +-NO---+
'-POOL-'
- DPMODI=HIGH|EQ|LOW
- Specifies
a default for the DPMODE parameter in other TYPEs of this macro.
- HIGH
- Specifies that subtasks can attain a higher priority than the CICS main
task from which the subtask was generated. Use this option for high priority
and high volume transactions.
- EQ
- Specifies that CICS must allow for subtasks to attain equal priority.
- LOW
- Specifies that subtasks have a lower priority than the CICS main task
priority.
- ERRDEST=(dest1,dest2,dest3)
- Specifies up
to three CICS transient data destinations to receive unsolicited messages.
For dest1,dest2,dest3,
substitute up to three valid transient data destinations.
An asterisk
can be specified as a destination. The asterisk acts as a place holder and
allows later specification of a destination by the DSNC MODIFY DESTINATION
command.
- PCTEROP=AEY9|N906D|N906
- Specifies the type
of processing that is to occur following a create thread error. The error
processing occurs after the SQLCA's SQLCODE field has been updated to reflect
the reason for the create thread failure. The PCTEROP parameter allows a user
to specify whether a transaction dump is taken, and whether the DSNCSQL RMI
associated with the transaction is disabled. This parameter can be used to
allow a transaction to continue processing if a create thread error occurs.
A transaction that continues after a create thread error must take corrective
action to allow a new thread to be created. A SYNCPOINT ROLLBACK command must
be part of the corrective action taken by the transaction before it can continue
to issue SQL requests.
- AEY9
- When the first SQL error is detected, CICS takes a transaction dump for
abend code AD2S, AD2T, or AD2U, depending on the type of error. For the first
error, the transaction does not abend. For a second or subsequent SQL error,
the transaction abends with abend code AD2S, AD2T, or AD2U. The transaction
must be terminated and reinitialized before it is allowed to issue another
SQL request.
- N906D
- Specifies that a transaction dump is to be taken and the DSNCSQL RMI associated
with the transaction is not to be disabled. The transaction receives
a -906 SQLCODE if another SQL is issued, unless the transaction issues SYNCPOINT
ROLLBACK. SYNCPOINT without the ROLLBACK option results in an ASP7 abend.
- N906
- Specifies that a transaction dump is not to be taken and the DSNCSQL
RMI associated with the transaction is not to be disabled. The transaction
receives a -906 SQLCODE if another SQL request is issued, unless the transaction
issues a SYNCPOINT ROLLBACK. SYNCPOINT without the ROLLBACK option results
in an ASP7 abend.
- PLANI=plan-name
- Specifies the default
plan name for any entry in the RCT that does not use dynamic plan selection.
The plan-name can have 1-8 characters. Without the PLANI option,
the plan name for an entry in the RCT is:
- The value for PLAN= in the TYPE=ENTRY macro
- The value for TXID= in the TYPE=ENTRY macro if PLAN= is not specified
With the PLANI option, the plan name for an entry in the RCT is:
- The value for PLAN= in the TYPE=ENTRY macro
- The value for PLANI= in the TYPE=INIT macro if PLAN= is not specified
- The value for TXID= in the TYPE=ENTRY macro if neither PLAN= nor PLANI=
is specified
The PLANI option has no effect on entries that use dynamic plan
selection.
- PLNPGMI=default-exit-name
- Specifies the name
of the default dynamic plan exit. If one of the entries has PLNEXIT=YES, but
does not supply a value for PLNPGME, this parameter is used as the exit program
name for that entry.
Default: DSNCUEXT
- PURGEC=minutes,seconds
- specifies
the length of the protected thread purge cycle. The maximum value for PURGEC
is (59,59). The minimum is (0,30).
An unprotected thread is terminated
as soon as the transaction ends (at SYNCPOINT or EOT). A protected thread
is terminated after two purge cycles, which are 30 seconds by default. Normally,
a protected thread remains connected for 30-60 seconds after the transaction
ends.
You can use PURGEC to modify the 'normal purge cycle'. The purge
cycle is 5 minutes long when the attachment starts and then PURGEC for the
remaining time that the attachment facility operates. For example, if you
specify PURGEC=(0,40), protected threads are normally purged 40-80 seconds
after the transaction ends.
- RDONAME=DB2CONN-name
- specifies
the name to be used for the DB2CONN when migrating the RCT to the CSD.
- ROLBI=YES|NO
- Specifies a default for the ROLBE parameter in other TYPEs of the DSNCRCT macro. The
specification of this parameter determines the disposition of transaction
entries in the event a transaction is selected by DB2 as victim in a deadlock
resolution.
- YES
- Specifies that the attachment facility is to issue a syncpoint rollback
before returning control to the application. A SQL return
code of -911 is returned to the program. Specifying YES provides compatibility
with SQL/DS.
- NO
- Specifies that the attachment facility is not to initiate a rollback for
this transaction. A SQL return code of -913 is returned to the application.
It is the responsibility of the application to initiate the rollback.
- SHDDEST=destination
- Specifies a transient data destination to receive the statistical report (the same report that
is displayed with the DSNC DISP STAT command) during shutdown of the attachment
facility. For destination, substitute a valid transient
data destination.
It might be useful to direct this transient output data
to a destination in another partition that is specified as a JES SYSOUT file.
- SIGNID=authorization ID
- Specifies
the authorization ID to be used by the CICS attachment facility when signing
on to DB2. For authorization ID, substitute a character
string of up to eight characters. The name can be up to eight characters in
length.
The default is the APPLID of the CICS system. This name is used
when indicated when AUTH=SIGNID is set on the TYPE=ENTRY or TYPE=POOL forms
of the macro. For a description of the AUTH parameter, see Entries in resource control table—DSNCRCT TYPE=ENTRY. When it is used, the name specified here must be authorized
to the resources being accessed.
- STANDBY=SQLCODE|ABEND
- Specifies the action to be taken by the attachment facility during the
startup process if DB2 is not active.
- SQLCODE
- Only valid if STRTWT=AUTO or YES is specified. If an application issues
a SQL statement while the attachment facility is standing by, SQLCODE -923
is issued instead of abend AEY9.
- ABEND
- Specifies CICS applications using DB2 fail with abend AEY9 issued by CICS
when the attachment is not started.
- STRTWT=AUTO|YES|NO
- Specifies the action
to be taken by the attachment facility during the startup process if DB2 is
not active.
- AUTO
- Specifies automatic restart of the attachment facility if DB2 stops or
abends, then restarts. The starting procedures are the same as for YES. If
DB2 stops or abends while the attachment facility is up, a message is issued
stating the subsystem is not active. The attachment facility goes to standby
state and only terminates after the command DSNC STOP is issued or an unrecoverable
error is encountered.
- YES
- Directs the attachment facility to wait for DB2 to start and complete
the connection. A CICS task waits to be posted by DB2 when DB2 becomes available.
At that time, the initialization of the CICS attach is complete. However,
the attachment facility can be terminated by the DSNC STOP command while it
is waiting for DB2.
The response messages from the attachment are sent
to the transient data destination queue specified in the ERRDEST parameter
of the RCT.
- NO
- Directs the attachment facility to terminate the connection process immediately
if DB2 is not already active.
- SUBID=DB2-ID
- Specifies the name of the DB2
subsystem that the attachment facility is to connect with CICS. For DB2
ID, substitute a character string of up to four characters.
- SUFFIX=XX
- Specifies the one or two characters that are concatenated with
DFHRCT to create the name of the resource control table. Acceptable characters
are A-Z 0-9 $ @ and #. Do not use NO, DY or BA. For more information about
TYPE=INITIAL macros, including the use of the SUFFIX operand, see TYPE=INITIAL (control section).
- THRDMAX=integer
- Specifies the maximum number of subtasks (TCBs)
that can be identified to DB2. The default is 12, the minimum value is 4.
The number controls the total number of threads for each region. For that
reason, the recommended value for THRDMAX is the sum of all values on the
THRDA parameters (COMD, ENTRY, and POOL threads) + 3. However, the value you
specify for THRDMAX can be less than the sum of all values on the THRDA parameter.
- TOKENI=NO|YES
- Specifies the default TOKENE if TOKENE
is not specified on the TYPE=ENTRY statement. For more information about TOKENE,
see Entries in resource control table—DSNCRCT TYPE=ENTRY.
- TXIDSO=YES|NO
- Specifies whether you want to suppress some sign-ons during
thread reuse, and thereby avoid extraneous accounting information. The TXIDSO
option affects only pool threads and those RCT entry threads with multiple
transaction IDs in one entry (for example, TXID=(XC05,XC07). The attach checks
for thread reuse only within an entry. TXIDSO has no effect on transactions
that specify TOKENE=YES. If the plan name changes, the thread is terminated
and recreated.
- YES
- Specifies the following rules for thread reuse:
- A new transaction can reuse an existing thread without a sign-on when:
- The authorization ID and transaction ID are the same as the last transaction
that used the thread, and TOKENE is set to NO.
- A new transaction must sign-on before reusing an existing thread when
any of these conditions exist:
- The authorization ID is different from the authorization ID that last
used the thread.
- TOKENE is YES.
- The transaction ID has changed.
- NO
- Specifies the following rules for thread reuse:
- A new transaction can reuse an existing thread without a sign-on when:
- The authorization ID is the same as the last transaction that used the
thread and TOKENE is set to NO.
- A new transaction must sign-on before reusing an existing thread when
either of these conditions exist:
- The authorization ID is different from the authorization ID that last
used the thread.
- TOKENE is YES.
- TWAITI=YES|NO|POOL
- Specifies the default value (YES, NO, or POOL) that is to be created for
the TWAIT parameter on other types of the macro.