Use DDM files with commitment control
DDM files can be opened under commitment control.
However, the following restrictions should be considered when working with these DDM files:
- If more than one DDM file (with PTCCNV(*NO)) is opened under commitment control, the following items must be the same for each file:
The exception to this rule is when all of the DDM files opened under commitment control are scoped to the job level. In this case, the activation group numbers are ignored and do not need to match.
- Remote location name
- Local location name
- Device
- Mode
- Remote network ID
- Transaction program name (TPN)
- User ID
- Activation group number
- Open scope
- If a DDM file and a remote SQL object (Distributed Relational Database Architecture™, DRDA®) are running under commitment control (with PTCCNV(*NO)), the following items must be the same for the file and object:
- Remote location name
- Local location name
- Device
- Mode
- Remote network ID
- TPN
- User ID
- Activation group number
- Open scope
- If the DDM file (with PTCCNV(*YES)) is being opened for output, update, or delete (not opened for input only), then there cannot be any one-phase DDM or DRDA conversations active.
- If a DDM with PTCCNV of *YES is being used, it must point to a target iSeries™ server that supports two-phase commitment control protocols.
- DDM files (with PTCCNV(*NO)) and local database files cannot be opened under commitment control at the same time within the same activation group.
- DDM files (with PTCCNV(*NO)) and local database files cannot be opened under commitment control at the same time within the same job if commitment control is scoped to the job level.
- To open a DDM file under commitment control and scope it to the job level, have specified CMTSCOPE(*JOB) on the Start Commitment Control (STRCMTCTL) command.
- You cannot use the Submit Remote Command (SBMRMTCMD) command to call programs that expect commitment control to be scoped to the job level. Because commitment control is always scoped to the activation group level in DDM target jobs, the program fails.
- The SBMRMTCMD command should not be used to start or end commitment control.
- The target server specified from the iSeries server working under commitment control must be another iSeries server.
If the communications line fails during a COMMIT operation, the source and target servers will do a ROLLBACK operation. However, the target server might successfully complete the COMMIT operation before the line fails, but the source server will always do a ROLLBACK operation.
Table 1. High-level language commit and rollback commands Operation ILE RPG programming language ILE COBOL programming language PL/I CL ILE C programming language Commit changes in transaction COMMIT COMMIT PLICOMMIT COMMIT _Rcommit Cancel entire transaction ROLBK ROLLBACK PLIROLLBACK ROLLBACK _Rrollback
Parent topic:
Commitment control support for DDM