VERIFY Command (for Experienced)
Summary
For basic information, go through the VERIFY Command (for Beginners)
VERIFY command is used to verify the status of the dataset.
The VSAM dataset may not be closed when the job terminates abnormally, and catalog entry is flagged to show that the dataset may be corrupt.
Before opening the dataset again, the VERIFY command is used to identify the end of the dataset and reset the catalog entry.
The explicit VERIFY function is bypassed if the VERIFY command is used on an LDS.
High-level syntax -
//JOBNAME JOB job-card-parameters
//STEP1 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
VERIFY Command
/*
Detail syntax -
//JOBNAME JOB job-card-parameters
//STEP1 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
VERIFY {FILE(ddname)| DATASET(dataset-name)}
[RECOVER]
/*
Parameters
The VERIFY command mandatory and optional parameters are specified below -
Mandatory Parameters
FILE (ddname)
- Specifies the ddname of the cluster or alternate index that is being verified.
- The dataset is deallocated at the VERIFY job step termination.
DATASET (dataset-name)
- Specifies the name of the cluster or alternate index that is being verified.
- If DATASET is specified, the object is dynamically allocated.
- The dataset is deallocated dynamically at job termination.
Short Description: DS
Example -
Requirement - Copy data from KSDS to PS file from E0003 to E0005.
Input ESDS File - MATEPK.EMPL.KSDS
Code -
----+----1----+----2----+----3----+----4----+----5----+----6----+----7--
***************************** Top of Data ******************************
//MATEPKV JOB (123),'MTH',CLASS=A,MSGCLASS=A,MSGLEVEL=(1,1),
// NOTIFY=&SYSUID
//************************************************************
//* EXPORT DATA FROM VSAM KSDS TO PS DATA SET
//************************************************************
//STEP010 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//INPUT DD DSN=MATEPK.EMPL.KSDS,DISP=SHR
//SYSIN DD *
VERIFY -
FILE(INPUT)
/*
//*
**************************** Bottom of Data ****************************
In the above JCL, MATEPK is the userid and change it as required.
Output -
Once the above JCL is submitted, check the MAXCC of the job for any errors. If the MAXCC is 00 or 04, then REPRO is successful..
********************************* TOP OF DATA **********************************
IDCAMS SYSTEM SERVICES TIME: 10:40:36
VERIFY -
FILE(INPUT)
IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 0
IDC0002I IDCAMS PROCESSING COMPLETE. MAXIMUM CONDITION CODE WAS 0
******************************** BOTTOM OF DATA ********************************