How to find the number of duplicates in a file using Sort?
Answer Posted / abhijit saha
Hope this JCL explains your query
//COUNTDUP JOB ,'COUNT DUPLICT',
// MSGCLASS=Q,CLASS=D,
// NOTIFY=&SYSUID
//STEP010 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN DD DSN=ABCXYZ.UTIL.TEST,DISP=SHR
//RPT DD SYSOUT=*
//TOOLIN DD *
OCCUR FROM(IN) LIST(RPT) NOHEADER BLANK -
ON(1,2,CH) ON(VALCNT,U04)
/*
INPUT: ABCXYZ.UTIL.TEST
AB
AB
AB
DC
DC
PQ
PQ
Output:
AB 3
DC 2
PQ 2
| Is This Answer Correct ? | 17 Yes | 10 No |
Post New Answer View All Answers
Name the statement which can be used to send data to another mvs jes3 node?
what is “Cond= even” and “Cond=only”?
What is use of restart and how to use it?
What is 'mounting' of volumes ? Is there anything that a programmer can do in it ? How to find currently mounted volume ?
What are the 2 types of parameters in dd statement?
What is the function of dd disp parameter?
Is it possible to left uncode disp? If yes, how?
whats the diff bw the evaluate also and and?
How can a stopped job be started again?
how would you create a temporary dataset? And where will you use them?
i want to store 20 digits . how will u do it in cobol ?
Explain how can the attributes of one sms dataset be copied to another dataset?
Can an individual step be restricted from using all the jobs allowed cpu time?
Explain the function of the dd dcb keyword?
Differentiate between addressing mode and run mode.