write a program to eliminate duplicate records in a input file
and send them to output file.

Answer Posted / naidu sekhar yandrapu

We can use JCL SORT utility using SYSIN DD * SUM fields =
none, will eliminate duplicate and store in a different dataset.


e.g
//SORTXSUM DD DSN=... Output eliminated by the SUM stm

//SYSIN DD *
SORT FIELDS=(1,3,CH,A)
SUM FIELDS=NONE , XSUM
/*

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Our issue is there seems to be a disconnect, or no link, between our SELECT statement and our SD. We had SELECT SORT-FILE and SELECT SORT-FILE ASSIGN TO SORTWRK. ASSIGN TO SORTWRK1 SORTWRK2 SORTWRK3 SORTWRK4. with SD SORT_FILE RECORD CONTAINS 7833 CHARACTERS. In either case, at run time, the system ignored our SORTWRK# DD statements and allocated 16 sort works with the SORTWK## naming convention. Any ideas why the system does not recognize the connection? We do not even need the SORTWRK DD statements. Thanks

2337


If you are current on the owner of a set, what is the difference between an obtain next and obtain first? Actually in which topic will we use dis???Plz explain it clearly

2661


What guidelines should be followed to write a structured cobol prgm?

673


explain sorting techniques in cobol program?

691


how to convert the recors form vsam file to db2 table tru file aid

2763






What do you understand by psb and acb?

666


What kind of error is trapped by on size error option?

740


Why is it necessary that file needs to be opened in I-O mode for REWRITE?

748


What is the difference between PIC 9.99 and PIC9v99?

782


how do you reference the rrds file formats from cobol programs

801


Difference between array and sub-script ?

1169


What are the different rules for performing sort operation?

763


What are the different types of condition in cobol and write their forms.

659


What are the different rules of SORT operation?

700


Which is not true about evaluate statement

1586