. Do everything from the foot of the main menu
for the database involved,
or beyond, via call qcmd.
. The instructions below assume the library involved
is TM4L. If not, use
your library name instead of TM4L in the instructions below.
. If the date or type or any other aspect of the
last regen is unknown or
uncertain, examine the data areas named ZZREGEN0-9. The last regen is
documented always in ZZREGEN0. More on this later.
. Regen menu opt 98, positively identify the CUSTddhhmm
backup files. These were the original CUST and FIELG file before they
were renamed. If BOTH these files do not exist, the last regen did not
rebuild the database.
. For safety, while in the regen menu, take option
92 to archive the
current definition in case it is needed again. Name it FIEG999999 or any
other name you choose.
SCENERIO 1 -- LAST REGEN WAS A FULL REGEN, ie 2 files exist.
. To be absolutely safe, backup or copy the entire
library, or maybe just
files CUST FIEL and FIELG at this point. Which of these you do (if any)
determines how hard it will be to recover if the recovery goes wrong.
EG, CUST data entered since the bad regen will be lost.
. Delete all logical files over the CUST file by
entering this command:
. Rename the physical CUST file (or delete it if
you are brave enough):
Rename it to CUST999999 or any other name you choose.
RNMOBJ TM4L/CUST *FILE CUST999999 or
. Rename the regen backup cust file back to the
real cust file name: (you
noted the name up above):
RNMOBJ TM4L/CUSTddhhmm *FILE CUST
. Copy the regen backup database layout over the
currently in the FIEL file:
CPYF TM4L/FIEGddhhmm TM4L/FIEL MBROPT(*REPLACE)
. Go to the regen menu and do a normal full regen.