i have two flat files.i want to select one record from that
file by using jcl.for example file1 contains emp
no,name,joining date. file2 has same details.emp no is
primary key. i will give empno.that emp details send to
outfile.please let me know if any one knows it.give sample
code.
Answer Posted / vs kumar
//SORTIN DD DSN=INPUTFILE1,DISP=SHR
//SORTOF01 DD DSN=X.Y.OUTFILE1,DISP=SHR
//SYSIN DD *
SORT FIELDS=COPY
OUTFIL FILES=01,STARTREC=1,ENDREC=1
/*
//SORTIN DD DSN=INPUTFILE2,DISP=SHR
//SORTOF02 DD DSN=X.Y.OUTFILE2,DISP=SHR
//SYSIN DD *
SORT FIELDS=COPY
OUTFIL FILES=02,STARTREC=1,ENDREC=1
/*
//STEP2 EXEC PGM=SORT
//SORTIN DD DSN=X.Y.OUTFILE1,DISP=SHR
// DD DSN=X.Y.OUTFILE2,DISP=SHR
//SORTOUT DD DSN=X.Y.OUTFILE,DISP=SHR
//SYSIN DD *
SORT FIELDS=COPY
/*
Is This Answer Correct ? | 0 Yes | 3 No |
Post New Answer View All Answers
What is the purpose of dd * statement in jcl?
I have a job called careerride and some steps in it as step1,step2. But I want to execute step2 before step1 ? How do I do that?
What is job control language?
How does the jcl specify the job to os?
Define concatenating?
What is the function of dd name parameter with a 2 part structure; audit.report?
I want to JCL sort for Non-COMP and COMP-3 fields SORT FIELDS=(1,5,A,6,11,A,12,11,A,19,1,A,20,1,A),FORMAT=BI,EQUALS Length of comp bytes is 11 bytes which start at 6byte and 12 byte considering 11 bytes in comp-3 is 6 bytes. Can anyone tell if the above sort work SORT FIELDS=(1,5,A,6,6,A,12,6,A,19,1,A,20,1,A),FORMAT=BI,EQUALS does not works OK
what is use of disp parameter in dd statement?
What are s0c1, s0c4, s0c5, s0c7 and socb?
when does a dataset go uncataloged?
Where can program checkpoints be stored for use in a restart?
what is use of dsn parameter in dd statement?
what are JCLLIB and STEPLIB in JCL?
How is a type of file defined in the jcl that executes the cobol program?
Is it possible to define dd statements as you want?