Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Need help with a PDS to GDG copy
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 3:10 am    Post subject: Need help with a PDS to GDG copy
Reply with quote

I need to copy the contents of a PDS file into a GDG that will allow the members to be edited. I have tried IEBCOPY, IEBGENER, ICETOOL, FILEMGR, SORT, IDCAMS and IEBPTPCH and combinations of both.

This was my last attempt using a combo of IEBPTPCH and SORT, it catalogs the data set but as a flat file. Anyone see anything that I am doing inccorectly.

//STEP020 EXEC PGM=IEBPTPCH,COND=(0,NE)
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=JOBTRAC.STAGING.SCLLIB1,DISP=SHR
//SYSUT2 DD DSN=X580226.DUMP.OF.MY.PDS.PS,
// DISP=(NEW,CATLG,DELETE),
// SPACE=(CYL,(5,5),RLSE),
// UNIT=SYSDA,
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=0)
//SYSIN DD *
PUNCH TYPORG=PO
/*
//STEP030 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//REPORT1 DD SYSOUT=*
//SORTIN DD DSN=X580226.DUMP.OF.MY.PDS.PS,DISP=SHR
//SORTOUT DD SN=JOBTRAC.STAGING.SCLLIB.BKUP+1),
// DISP=(NEW,CATLG,CATLG),UNIT=SYSDA,SPACE=(CYL,(2,2)),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=0)
//SORTWK01 DD UNIT=DISK,SPACE=(CYL,(20,5),RLSE)
//SORTWK02 DD UNIT=DISK,SPACE=(CYL,(20,5),RLSE)
//SORTWK03 DD UNIT=DISK,SPACE=(CYL,(20,5),RLSE)
//SYSIN DD *
SORT FIELDS=COPY

/*
Back to top
View user's profile Send private message

gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 3:55 am    Post subject:
Reply with quote

Hi,

what exactly are you trying to do ? Are you trying to take a copy/backup of a PDS, in other words create another PDS and copy the contents of PDS1 to PDS2.

I'm certainly unsure what you are requesting.

Gerry
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1738
Location: Bloomington, IL

PostPosted: Thu Apr 28, 2011 4:09 am    Post subject:
Reply with quote

Asked and answered years ago.

ETA: That JCL isn't creating a PDS and has at least one syntax error in it that would prevent it from running anyway. I think that you need to 'fess up and tell us what you're really trying to do and what you've really done.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 4:10 am    Post subject:
Reply with quote

I am trying to copy the PDS into a GDG that will be essentially a PDS like data set, allow editing, copies, moves of individual member. Yes this is for backup reasons. if a restore of a member is needed we can pull it back into the original library.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 4:30 am    Post subject:
Reply with quote

Akatsukami, Wouldn't have asked the question if I hadn't exhausted all of my available resources. Searched the site high and low for this information and it never popped out. Thanks for pointing me at the correct location. I'll see what I can come up with after I read these documents. Based on a brief look, think the whole process may have to be re-evaluated and a different approach investigated. Thanks again!
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 4:32 am    Post subject:
Reply with quote

Hi,

i would opt for IEBCOPY, example below
Code:
//STEP01   EXEC PGM=IEBCOPY                                     
//SYSPRINT DD SYSOUT=*                                         
//SYSUT3   DD UNIT=SYSDA,SPACE=(CYL,(2,1))                     
//SYSUT4   DD UNIT=SYSDA,SPACE=(CYL,(2,1))                     
//IN       DD DSN=input-dsn,DISP=SHR                           
//OUT      DD DSN=output-dsn,                                   
//            DISP=(,CATLG,DELETE),                             
//            LIKE=input-dsn                                   
//SYSIN    DD *                                                 
 COPY INDD=IN,OUTDD=OUT                                         
/*



Gerry


Gerry
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 4:50 am    Post subject:
Reply with quote

My JCL runs to completion with all condition code zero's but the output GDG is a flat file that just lists the pds members. So I am not sure what syntax error you are seeing. I am not that familar with either IEBPTPCH or SORT. When I used FILEMGR the data set was also created but again as a listing not an edit friendly data set. IEBCOPY, IEBGENER, ICETOOL and IDCAMS are all failing with a cond code 12 wrong length record on the input file, I have tried to use quickref for a fix but doesn't provide much info and I have always been on the other side of these types of abends so I'm not sure what needs to be done or how to correct it. Never used ICETOOL until I began this project. Have used the other utilities but it has been a while. Hope this counts as a confession, not sure what else to say.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 4:55 am    Post subject:
Reply with quote

gcicchet, I tried using IEBCOPY and the job keeps failing on a wrong length record on the input dsn. I don't know enough about this type of error to know how to fix it or what is causing it. But thanks I appreciate the info.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 4:59 am    Post subject:
Reply with quote

Hi,

you need to show the JCL used and output from run.


Gerry
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:00 am    Post subject:
Reply with quote

Gerry, This is the IEBCOPY JCL I was using:
//STEP020 EXEC PGM=IEBCOPY,COND=(0,NE)
//SYSPRINT DD SYSOUT=*
//SYSUT3 DD UNIT=SYSDA,SPACE=(TRK,(90,90))
//SYSUT4 DD UNIT=SYSDA,SPACE=(TRK,(90,90))
//IN DD DSN=JOBTRAC.STAGING.SCLLIB1,DISP=SHR
//OUT DD DSN=JOBTRAC.STAGING.SCLLIB.BKUP(+1),
// DISP=(,CATLG),
// UNIT=SYSDA,SPACE=(TRK,(5,5),RLSE),
// DCB=(RECFM=FB,LRECL=80,
// DSORG=PS,BLKSIZE=0,BUFNO=30)
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=6080)
//SYSIN DD *
COPY INDD=((IN,R)),OUTDD=OUT
//
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:01 am    Post subject:
Reply with quote

There is a 2nd DCB statement that was commented out when I ran the job.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:02 am    Post subject:
Reply with quote

Tried DSORG= PS, PO
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 5:12 am    Post subject:
Reply with quote

Hi Darrel,

you need to provide the information requested.

1. exact JCL you ran

2. all output including messages

3. what is the LRECL amd RECFM of the input PDS.

Also when creating a PDS, you need to specify directory blocks

Gerry
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:15 am    Post subject:
Reply with quote

I did get a couple of the IEBCOPY jobs to complete and catalog a data set. But when I tried to edit the data set I got and error "INVALID DSORG". I have run this job so many times and tried so many different PGMS that I am confused on what went wrong. The job that executed IEBGENER were failing with the CC12 wrong length record on the input file. Sorry I am so messed up. Been working on this for a few days and getting really frustrated.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:17 am    Post subject:
Reply with quote

Data Set Name . . . : JOBTRAC.STAGING.SCLLIB1

General Data Current Allocation
Volume serial . . . : SFTP06 Allocated cylinders : 70
Device type . . . . : 3390 Allocated extents . : 1
Organization . . . : PO Maximum dir. blocks : 500
Record format . . . : FB
Record length . . . : 80
Block size . . . . : 6080 Current Utilization
1st extent cylinders: 70 Used cylinders . . : 1
Secondary cylinders : 5 Used extents . . . : 1
Used dir. blocks . : 1
Creation date . . . : 2011/04/11 Number of members . : 5
Referenced date . . : 2011/04/27
Expiration date . . : ***None***
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:23 am    Post subject:
Reply with quote

Gerry, Thank you so much for trying to help me. I saw the need for directory blocks in some of my abend messages. How do I specify that in my DCB parm?
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 5:26 am    Post subject:
Reply with quote

Hi,

why don't you use the JCL I provided.

Also you must provide the SYSOUT from the the job you are running.




Gerry
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:30 am    Post subject:
Reply with quote

Gerry, The sysout goes to SAR, I have to restore it. It takes a while to get it reloaded. I will make a copy of your JCL and try that out. I'm at work and have to get busy doing something else (sorry). I do not want to take up any more of your time. I really thank you for all the effort.
Back to top
View user's profile Send private message
Darrell Wilson

New User


Joined: 07 Apr 2011
Posts: 14
Location: United States

PostPosted: Thu Apr 28, 2011 5:33 am    Post subject:
Reply with quote

I'll let you kn ow if your JCL solved my problem. Have a feeling that it will.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Apr 28, 2011 5:34 am    Post subject:
Reply with quote

Hi Darrell,

directory blocks are part of the space parameter

eg. SPACE=(TRK,(5,5,10),RLSE)


Gerry
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am
No new posts Single COPY CICS TS datasets and when... Kyle Carroll CICS 2 Tue Oct 11, 2016 9:47 pm
No new posts dataset copy question - REPRO or some... atulxp TSO/ISPF 2 Wed Aug 03, 2016 10:56 pm
No new posts How to copy Tape dataset to unix main... chaky All Other Mainframe Topics 4 Fri Jul 08, 2016 2:52 am
No new posts Using Field names in FILEAID Batch CO... Atul Banke Compuware & Other Tools 2 Wed Jun 29, 2016 9:54 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us