How IMS Log can be read for updates done to IMS Database
Solution
Below control card can be used to get all updates done to the database DBNAME . Which extracts database records ( X’50’ ) with all Subtypes for a given database.
//SYSIN DD *
CONTROL CNTL DDNAME=LOGIN,DDNOUT=LOGOUT
OPTION COPY PRTSYS=Y,OFFSET=5,FLDTYP=X,VALUE=50,FLDLEN=1,COND=M
OPTION COPY PRTSYS=Y,OFFSET=53,FLDTYP=C,VALUE=DBNAME,FLDLEN=8, X
COND=E
END
Just for your information , we used ILOGREC for getting IMS Log record structure।
*********************************************************************** ** D A T A B A S E X ' 5 0 ' L O G R E C O R D ** ** ** ** SUBCODE X'50' RECORDS CONTAIN UNDO DATA FOR DATA BASE ** ** BACKOUT AND REDO DATA FOR DATA BASE RECOVERY. ** ** SUBCODE X'51' RECORDS HAVE NO DATA AND INDICATE THE ACTION ** ** LOGGED BY THE PRIOR RECORD WAS UNSUCESSFUL. ** ** SUBCODE X'52' RECORDS CONTAIN UNDO DATA LOGGED BEFORE ** ** AN INSERT TO A KSDS DATASET. SUBSEQUENT SUBCODE 50/51 ** ** RECORDS INDICATE WHETHER THE INSERT WAS SUCCESSFUL. ** ***********************************************************************
Sample JCL
//STEPM EXEC PGM=DFSERA10,REGION=6M
//STEPLIB DD DSN=IMSVS.IMSSYS.RESLIB,DISP=SHR
//SYSPRINT DD SYSOUT=*
//LOGIN DD DSN=READ.LOGFILE,UNIT=TAPEC,
// DISP=(OLD,KEEP,KEEP),VOL=SER=F07113
//LOGOUT DD SYSOUT=*
//SYSIN DD *
CONTROL CNTL DDNAME=LOGIN,DDNOUT=LOGOUT OPTION COPY PRTSYS=Y,OFFSET=5,FLDTYP=X,VALUE=50,FLDLEN=1,COND=M
OPTION COPY PRTSYS=Y,OFFSET=53,FLDTYP=C,VALUE=DBNAME,FLDLEN=8, X
COND=E END
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment