How do I merge PDSMAN Database files?
search cancel

How do I merge PDSMAN Database files?

book

Article ID: 262050

calendar_today

Updated On:

Products

PDSMAN

Issue/Introduction

How do I merge PDSMAN database files?

Environment

PDSMAN Release : 7.7

z/OS

Resolution

Use IDCAMS JCL to create a copy of the database.

//REPRO    EXEC PGM=IDCAMS                                      
//SYSUT1   DD DISP=SHR,DSN=PDSMDB.old
//SYSUT2   DD DISP=SHR,DSN=PDSMDB.new
//SYSPRINT DD SYSOUT=*                                    
//SYSIN    DD *                                           
  REPRO IFILE(SYSUT1) OFILE(SYSUT2) NOREPLACE ELIMIT(9999)

Because of the structure and key format of the PDSMAN database IDCAMS should NOT be used to merge two files.

When merging two already existing files the PDSM38 COPY command should be used.

For example:

  1. IDCAMS REPRO to copy MVS1 to the newly allocated DEV database
  2. PDSM38 COPY to merge MVS2 into the new DEV created by IDCAMS
  3. PDSM38 COPY to merge MVS3 into the new DEV

The PDSM38 COPY commands would look like:

 COPY DSN=-                   
         REPORT=SUMMARY         
         REPLACE              
          FROMDB=input database ddname      
          TODB=the new database

********************

Example: 

//JOBCARD                          
//**********************************************************
//**********************************************************
//*     PDSM38 COPY TO MERGE DATABASES 
//**********************************************************
//M38RPT  EXEC PGM=PDSM38,REGION=0M                         
//TDB      DD  DISP=SHR,DSN=yourHLQ      
//PDSMRPT  DD  SYSOUT=*                                     
//SYSIN    DD  *                                            
COPY DSN=-                   
         REPORT=SUMMARY         
         REPLACE              
          FROMDB=input database ddname      
          TODB=the new database