I had Records in file Like this
Company Code
IBM 2
IBM 1
IBM 4
WIPRO 3
WIPRO 2
WIPRO 9
TCS 4
TCS 6
TCS 3
i want the record of every company with highest code How can
i do that?
Answer Posted / sathish
//STEP1 EXEC PGM=SORT
//SORTIN DD *
IBM 2
IBM 1
IBM 4
WIPRO 3
WIPRO 2
WIPRO 9
TCS 4
TCS 6
TCS 3
//SORTOUT DD DSN=D362967.TEST.PS1,DISP=SHR
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=(1,12,CH,D)
/*
//STEP1 EXEC PGM=SORT
//SORTIN DD DSN=D362967.TEST.PS1,DISP=SHR
//SORTOUT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=(1,5,CH,A)
SUM FIELDS=NONE
/*
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
can any one plzzzzzz tell the jcl code for creating ps using idcams
Explain how can an in-stream dataset be terminated?
Suppose I have a program in cobol name ”careerride” and want to execute the program by jcl. Specify the process?
What are the parameter we cannot use in procedure? How many instream we can write in single jcl?
How to code these statements in JCL: CLEANUP INITIAL(NO) RESTART(NO) DYNALLOC(NO) job definition..?
what is use of dcb parameter in dd statement?
what is a jcl?
I have many files which i am receiving from client everyday. I have one step for every file to check for empty or not. Here client gives 30 files i need to check for every file for empty or not and i need to perform 30 steps. Can I do it in single step. Dynamically i need to change the File name in my step.
I HAVE A VB BLOCK WHICH IS USED AS INPUT IN COBOL CONATINING SOME RECORDS CAN I CHANGE THE FILE FROM VB TO FB?
why should SYSIN DD * statement should not be included inside a PROCedure snippet??? please answer this.. i need to know.
What are hierarchy levels in jcl?
Explain how can the attributes of one sms dataset be copied to another dataset?
What do you understand by the terms: joblib and steplib?
What is the function of the dd dcb keyword?
How to pass the parameter in parm using linkage section ? (syntax)?