Commit-point processing in MSDBs and DEDBs
Your existing application programs can use either the MSDB commit view or the default DEDB commit view.
MSDB commit view
When you update a segment in an MSDB, IMS™ does not apply your updates immediately. Updates do not go into effect until your program reaches a commit point.
As a result of the
way updates are handled, you can receive different results if you
issue the same call sequence against a full-function database or a
DEDB and an MSDB. For example, if you issue GHU and REPL calls
for a segment in an MSDB, and then issue another Get call for the
same segment in the same commit interval, the segment that IMS returns to you is the old
value,
not the updated one. If, however, you issue the same call sequence
for a segment in a full-function database or DEDB, the second Get
call returns the updated segment.
When the program reaches a commit point, IMS also reprocesses the FLD VERIFY/CHANGE call. If the VERIFY test passes, the change is applied to the database. If the VERIFY test fails, the changes made since the previous commit point are undone, and the transaction is reprocessed.
DEDBs with MSDB commit view
To use the MSDB commit view for DEDBs, specify VIEW=MSDB on the PCB statement; if you do not specify VIEW=MSDB, the DEDB uses the default DEDB commit view. So no changes to any existing application programs are required in order to migrate your MSDBs to DEDBs.
Assume that you specify VIEW=MSDB in the PCB and an application program issues GHU and REPL calls to a DEDB followed by another GHU call for the segment in the same commit interval. Then the application program receives the old value of the data and not the new value from the REPL call. If you do not specify VIEW=MSDB, your application program receives the new updated values of the data, just as you expect for a DEDB or other DL/I database.
You can specify VIEW=MSDB for any DEDB PCB. If it is specified for a non-DEDB database, you receive message DFS0904 during ACBGEN.
If you issue a REPL call with a PCB that specifies VIEW=MSDB, the segment must have a key. This requirement applies to any segment in a path if command code 'D' is specified. Otherwise, the AM status code is returned. See IMS Version 13 Messages and Codes, Volume 4: IMS Component Codes for information about that status code.
The following code shows an example of a PCB that specifies the VIEW option.
Sample PCB specifying View=MSDB
PCB , *00000100
TYPE=DB, *00000200
NAME=DEDBJN21, *00000300
PROCOPT=A, *00000400
KEYLEN=30, *00000500
VIEW=MSDB, *00000600
POS=M 00000700