write a program to eliminate duplicate records in a input file
and send them to output file.THIS IS IGATE RECENT
QUESTIONN.....JUST 1 WEEK BACKKKK...

Answer Posted / kumarmf2004

Step1. Make sure that the input is sorted on the field
you are validating as duplicates (IN-FIELD in this
case)
Step2. In your program
IF IN-FIELD = HOLD-FIELD
CONTINUE
ELSE
WRITE OUTREC
MOVE IN-FIELD TO HOLD-FIELD
END-IF
READ IN-FILE

Keep performing Step 2 until end of file

Is This Answer Correct ?    7 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

2 input fles: 2 flat files, with different number of records. both are having unique key for each record and already sorted in ascending order . match these files using unique key and in output only matching key value has to be written. please procide cobol logic

2358


System Testing for Mainframe Developers What is System Testing? integration testing ? what's the procedure ..

1817


Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning

863


Write a program to enter and display the names of students in a class using the occurs clause.

915


How do we get current date from system with century in COBOL?

1056


INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?

620


i was faced one question- i have value -00001234.56 Suppress the zeroes and the output should be -1234.56 But Not - 1234.56 spaces should not be available after suppressing the zeroes. logic in jcl and cobol?

1076


Which is not true about evaluate statement

2088


How do you reference the following file formats from cobol programs?

906


what is s000 u4087 error? please give the all error codes in cobol,jcl.

17508


How arrays can be defined in COBOL?

828


How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?

905


How are the next sentence and continue different from each other?

1005


What is inspect in cobol ?

1000


) what is the difference between AID and HANDLE AID?

1882