Hi,
Say I have 10 flat files and I want to copy all these 10
flat files to a GDG versions flat files (I have GDG base:
FDWS01.TEST.RESTORE) in one shot. Can we do that in one shot
using a JCL. May be by using IEBGENER. It's a bit urgent. So
anyone's fast rely would be appreciated.. Thanks in advance..
10 flat files
-----------------------------------
FDWS01.SUB.RESTORE1
FDWS01.SUB.RESTORE2
FDWS01.SUB.RESTORE3
;
;
FDWS01.SUB.RESTORE10
TO
GDG versions
-----------------------
FDWS01.TEST.RESTORE.G0001V00
FDWS01.TEST.RESTORE.G0002V00
FDWS01.TEST.RESTORE.G0003V00
;
;
FDWS01.TEST.RESTORE.G0010V00
Answers were Sorted based on User's Feedback
Answer / balmukund
Using below JCL we can achieve the above task.
//jobcard JOB.......
//STEP1 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//INDD DD DSNAME=FDWS01.SUB.RESTORE1,DSIP=OLD
// DD DSNAME=FDWS01.SUB.RESTORE2,DSIP=OLD
// DD DSNAME=FDWS01.SUB.RESTORE3,DSIP=OLD
// DD DSNAME=FDWS01.SUB.RESTORE4,DSIP=OLD
......
......
......
// DD DSNAME=FDWS01.SUB.RESTORE10,DSIP=OLD
//OUTDD DD DSNAME=FDWS01.TEST.RESTORE(+1),DISP=NEW
//SYSIN DD *
REPRO INFILE (INDD) OUTFILE (OUTDD)
/*
Hope this will work with you. other wise let me known
Is This Answer Correct ? | 6 Yes | 1 No |
Answer / lu
your questions is 10 flat files copy into 1 output !!! or
10 flat file into 10 output !!!!
u create 10 steps (10 flat files into 10 output with GDG
//STEP1 EXEC PGM=IEBGENER
//sysut1 DD DSN=FDWS01.SUB.RESTORE1,DISP=old
//SYSUT2 DD DSN=FDWS01.TEST.RESTORE(+1),
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(TRK,(20,10),RLSE),
// DCB=(MODEL.DCB,RECFM=FB,
// LRECL=80, BLKSIZE=800)
//*
//*
//STEP02 EXEC PGM=IEBGENER
//sysut1 DD DSN=FDWS01.SUB.RESTORE2,DISP=old
//SYSUT2 DD DSN=FDWS01.TEST.RESTORE(+2),
// DISP=(NEW,CATLG,DELETE),
// UNIT=SYSDA,
// SPACE=(TRK,(20,10),RLSE),
// DCB=(MODEL.DCB,RECFM=FB,
// LRECL=80, BLKSIZE=800)
ok.....
Is This Answer Correct ? | 4 Yes | 2 No |
Answer / rakesh jena
Simply you will copy all the 10 flat files into GDG base.
Then thry ISPF3.4 option menu you can see all the o/p of
flat would be available in last 10 current version of GDG
file. Please let me know if i am wrong but after try once.
We are using this method always in our pjct.
Is This Answer Correct ? | 3 Yes | 3 No |
@Balmukund : Ultimate reply:
Same can be done by following method:
Sort all the 10 files on a ASC KEY.
Merge them and copy them to any file (Or GDG).
Let me know if you ned JCL for this. I hope u can do it and post the JCL for others.
Thnx, pls let us know the result
Garry
Is This Answer Correct ? | 0 Yes | 0 No |
can u explain gdg with example wht happens if we give limit,empty,noempty,scartch and no scartch
How to release a JOB (from the input queue) held by TYPRUN = HOLD ? and how to see the installation default time after which a JOB will be automatically released ? How to see the list of currently HELD JOBS ?
There are two steps in a JCl, the first one generates a report while the second step send an email saying the report has been generated, but the second steps should only be executed when the report file is non-empty. How can it be acheived. We may include steps in between.
What is the motivation behind coding class parameter in job statement?
How to read and write a single record into a file. I would like to use it to enter a single 8-character piece of information and use it to put it into a variable for processing in JCL. Thank you
The disp in the JCL is MOD and the program opens the file in OUTPUT mode. What happens ? The DISP in the JCL is SHR and the program opens the file in EXTEND mode. What happens ?
how to write a jcl prog to copy alternate recs from ps1 to another ps2,suppose ps1 having 10 recs?
What is job control language?
How do you pass parameters to the program as the job is being executed ?
In sms datasets, what is the function of the dd avgrec keyword?
Explain about LMMFIND - find a library member
lines(1,cancel)??What is meant by that??Plz explain it....