InterviewSolution
| 1. |
How Do You Use Commitment Control In Rpg? |
|
Answer» With commitment control, you ensure one of TWO outcomes for the file operations: either all of the file operations are successful or none of the file operations has any EFFECT. In this way, you process a group of operations as a unit. To use commitment control, you do the following: • Use the CL commands CRTJRN (Create Journal), CRTJRNRCV (Create Journal Receiver) and STRJRNPF (Journal Physical File) to prepare for using commitment control, and the CL commands STRCMTCTL (START Commitment Control) and ENDCMTCTL (End Commitment Control) to notify the SYSTEM when you WANT to start and end commitment control. • Specify commitment control on the file-description specifications of the files you want under commitment control. • Use the COMIT (Commit) operation code to apply a group of changes to files under commitment control, or use the ROLBK (Roll Back) operation code to eliminate the pending group of changes to files under commitment control. With commitment control, you ensure one of two outcomes for the file operations: either all of the file operations are successful or none of the file operations has any effect. In this way, you process a group of operations as a unit. To use commitment control, you do the following: • Use the CL commands CRTJRN (Create Journal), CRTJRNRCV (Create Journal Receiver) and STRJRNPF (Journal Physical File) to prepare for using commitment control, and the CL commands STRCMTCTL (Start Commitment Control) and ENDCMTCTL (End Commitment Control) to notify the system when you want to start and end commitment control. • Specify commitment control on the file-description specifications of the files you want under commitment control. • Use the COMIT (Commit) operation code to apply a group of changes to files under commitment control, or use the ROLBK (Roll Back) operation code to eliminate the pending group of changes to files under commitment control. |
|