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

Answers were Sorted based on User's Feedback



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

Answer / 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

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

Answer / ehatesham

//SORTXSUM DD DSN=datasetname,
// DISP=(NEW,CATLG,DELETE),UNIT=SYSDA,
// SPACE=(CYL,(1,4),RLSE),
// DCB=(RECFM=FB,LRECL=80,BLKSIZE=800)
.
.
//SYSIN DD *
SORT FIELDS=(1,3,CH,A)
SUM FIELDS=NONE,XSUM
/*

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More COBOL Interview Questions

What is 77 level used for ?

12 Answers   IBM, iGate,


What are the pertinent COBOL commands?

0 Answers   Satyam,


If we use GO BACK instead of STOP RUN in cobol?

2 Answers   Temenos,


i have the following varibles in the working storage 05 ws-A PIC X(30) VALUE 'ABCDEFGHIJKLMNOPQRESTUVWXYZ ' 05 WS-B REDEFINES WS-A 10 WS-B1 PIC X(10). 10 WS-B2 PIC 9(10). 10 WS-B3 PIC X(10). If I Display B1, B2 and B3 respectively, what is the value displayed in B2

9 Answers  


what are decleratives in cobol?

0 Answers   GGG, Satyam,


copy 100 records without using ibm utilities

3 Answers  


What is the difference between Structured COBOL Programming and Object Oriented COBOL ?

1 Answers  


What is difference between com and com3? Eg. s9(4) so what is the memory it will occupy com and com3.

2 Answers  


What does the INITIALIZE verb do?

1 Answers  


IF there 5 to 6 files in a JCL and there is some space abends, how can we identify which file has space abend and what can be done to get off that abend or rectify that abend.

2 Answers   ADNA, CSC,


In A cobol program , we can use COPY Statement in FILE- SECTION / WORKING-STORAGE SECTION / ENVIRONMENT DIVIION basically what is the difference

3 Answers   IBM,


Explain call by context by comparing it to other calls.

1 Answers  


Categories