234 LOBs with DB2 for z/OS: Stronger and Faster
Example 7-41 SPUFI update invalid LOB
UPDATE ##T.NORMEN03
SET IMAGE = BLOB('INVALID LOB')
WHERE DOC_ID LIKE '%E%' ;
---------+---------+---------+---------+---------+---------+
DSNE615I NUMBER OF ROWS AFFECTED IS 6
DSNE616I STATEMENT EXECUTION WAS SUCCESSFUL, SQLCODE IS 0
---------+---------+---------+---------+---------+---------+
---------+---------+---------+---------+---------+---------+
DSNE617I COMMIT PERFORMED, SQLCODE IS 0
DSNE616I STATEMENT EXECUTION WAS SUCCESSFUL, SQLCODE IS 0
Afterwards, CHECK LOB SHRLEVEL REFERENCE does not find invalid LOBs anymore and
the AUXW pending status on the LOB table space is reset.
More complicated scenarios could involve point in time recovery, but here the same
techniques apply as in the first scenario. The basic principles remain:
򐂰 LOBs with missing log records between the used image copy and the recovery point are
marked
invalid by RECOVERY and the LOB table space is put in the auxiliary warning
state
(AUXW). CHECK LOB is needed to identify the invalid LOBs, and SQL can be used
to populate them again using update or by deleting the entire row.
򐂰 If you do not recover the base table space and LOB table spaces together to a common
point of consistency, the base table space is marked as
auxiliary check pending (ACHKP).
CHECK DATA is needed to identify and invalidate the LOBs, which are no longer
synchronized between the base and LOB table space, and SQL can be used to populate
them again using update or by deleting the entire row.
7.2.3 NOT LOGGED base table space with NOT LOGGED LOB table space
In the third scenario, we create both the base table space as NOT LOGGED and the LOB
table space as NOT LOGGED. We then redo the following steps:
1. LOAD the data.
2. Create a common recoverable point of consistency using the COPY utility with LISTDEF
and SHRLEVEL REFERENCE as shown in Example 7-11 on page 221. In
SYSIBM.SYSCOPY, we now get a common START_RBA = X'0002BB16C862’.
3. Delete six LOBs using SPUFI as shown in Example 7-13 on page 222 to create some
update activity. As a result, both the base table space and the LOB table space and all
underlying indexes are put in the informational copy (ICOPY) status, because no changes
have been logged at all.
4. Stop and start all spaces of database NORMEN03 and delete the VSAM clusters using
ISPF 3.4 as shown in Example 7-14 on page 222.
5. Recover the VSAM clusters back to the current point with the same statements as shown
in Example 7-15 on page 222. The job output is shown in Example 7-42.
Example 7-42 RECOVER of NOT LOGGED objects
DSNU000I 223 18:37:16.58 DSNUGUTC - OUTPUT START FOR UTILITY, UTILID = RECOV.NORMEN03
DSNU1044I 223 18:37:16.64 DSNUGTIS - PROCESSING SYSIN AS EBCDIC
DSNU050I 223 18:37:16.65 DSNUGUTC - LISTDEF MYLIST INCLUDE TABLESPACES TABLE ##T.NORMEN03 ALL INCLUDE
INDEXSPACES TABLE ##T.NORMEN03 ALL
DSNU1035I 223 18:37:16.65 DSNUILDR - LISTDEF STATEMENT PROCESSED SUCCESSFULLY
DSNU050I 223 18:37:16.65 DSNUGUTC - RECOVER LIST MYLIST PARALLEL
DSNU1033I 223 18:37:16.67 DSNUGULM - PROCESSING LIST ITEM: TABLESPACE NORMEN03.NORMEN03

Get LOBs with DB2 for z/OS: Stronger and Faster now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.