I have to copy these records to different members of a new PDS based on the first 3 bytes. All records with '001' as first 3 bytes should be written to a member named DSN001. similarly,
with '002' to member DSN002,
with '003' to member DSN003.
this may go till '099' to member DSN099.
I tried some thing like this. but gave an error saying that space specification incorrect.
Code:
//JS10 EXEC PGM=IEBGENER
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DSN=MY.SEQ.FILE.LIB,
// DISP=SHR
//SYSUT2 DD DSN=MY.PDS.FILE.LIB,
// DISP=SHR
//SYSIN DD *
GEN1 GENERATE MAXNAME=4,MAXGPS=3
MEM1 MEMBER NAME=DSN001
GRP1 RECORD IDENT=(3,'001',1)
MEM2 MEMBER NAME=DSN002
GRP2 RECORD IDENT=(3,'002',1)
MEM3 MEMBER NAME=DSN003
GRP3 RECORD IDENT=(3,'003',1),
MEM4 MEMBER NAME=DSN004
GRP4 RECORD IDENT=(3,'004',1)
/*
Eventhough i have used an existing file here(SYSUT2....DISP=SHR), Actualy my requirement is to create a new PDS and write into its members.
Please help me.
Can i handle this requirement of multiple members in a pds, using SYNCSORT or DFSORT utility also???
Actualy I tried something with
Joined: 04 Aug 2008 Posts: 9 Topics: 5 Location: BANGALORE
Posted: Sun Jan 04, 2009 3:04 pm Post subject:
Hi Kolusu,
Yes it worked. Thank you very much for your suggestion.
The problem was that I was using a PDS as output in my JCL
Now I changed it to a PDSE or library and it worked. _________________ Thanks and Regards,
Sebastian Joseph
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum