Please go thru the below points and let me know how to code
this.
1. Sort the input dataset for the condition : Starting
position is 37,length of the field is 13 based on character
and in the ascending order , starting from position 25
length of 12 ,character and in the ascending order. Use a
temporary dataset to hold the sorted file.
2. Use the temporary file created in the above step as the
input for the next step. The next step is to execute a
program and produce an output file. Use the temporary file
created in the above as work file 1 and the output of the
file to be created in this step work file 2.Also, pass a
parameter to the program that is to be executed in this
step. The parameter should have the current date in
YYYYMMDD format.

For the sake of convenience, you can use the below
Job Name : Sample1
Input DSN : PCABDT11.CABD.TEST.INPUT
Temporary DSN : Sort1
Output DSN : PCABDT11.CABD.TEST.OUTPUT
Program Name : SAMPLE

Thanks in Advance for your response.

Answers were Sorted based on User's Feedback



Please go thru the below points and let me know how to code this. 1. Sort the input dataset for t..

Answer / praveen kumar

Anju,,

IN your JCL, where are you using the wrkfile1(step1 output
file) in step2..

does it make any sense...

Is This Answer Correct ?    0 Yes 0 No

Please go thru the below points and let me know how to code this. 1. Sort the input dataset for t..

Answer / anju

//step1 exec pgm=sort
//sortin dd dsn= PCABDT11.CABD.TEST.INPUT,disp=shr
//sortout dd dsn=&&sort1, disp=(new,catlg,delete),
// unit=disk, space=(cyl(1,10),rlse),
// dcb=*.sortin
//sysin dd *
sortfields=(37,13,CH,A,25,12,CH,A)
/*
//sysout dd sysout=*
//sysprint dd sysout=*
//step2 exec pgm=sample,parm='2010/11/05'
//wrkfile2 dd dsn=PCABDT11.CABD.TEST.OUTPUT,
// disp=(new,catlg,delete),
// unit=disk, space=(cyl(1,10),rlse),
// dcb=*.sortin
//

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More JCL Interview Questions

whats the difference between empty and noempty of GDG?

4 Answers   Patni,


In sms datasets, what is the function of the dd avgrec keyword?

0 Answers  


what r the types of job control statements?

2 Answers  


What is the use of the utility DFSRRC00 in the JCL?

2 Answers   Convergys,


Can we use COND=EVEN on a job card, when jobs are scheduled through scheduler?

5 Answers   L&T,






how you will define a temporary dataset in jcl?

1 Answers   IBM,


Is automatic restart possible in jcl? If yes, how?

0 Answers  


Explain in DD statement what is the use of DCB parameter?

0 Answers  


What is the difference between the JOBLIB and the STEPLIB statements?

3 Answers  


What parameters can be used to limit the number of records written to a sysout dataset?

0 Answers  


how can i use the parameters decalred in main pgm in sub pgm

2 Answers   TCS,


What are the 2 types of parameters in dd statement?

0 Answers  


Categories