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

What is redefines clause in COBOL?

849


Write the code to count the sum of n natural numbers.

699


What is the Purpose of POINTER Phrase in STRING command in COBOL?

721


Explain what you understand by passing by value.

698


What is the difference between a binary search and a sequential search what are the pertinent cobol?

735






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

805


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

648


Write a program to explain size error.

675


How can you get the ksds file records into your cobol program?

642


What type of SDLC u followed? Why?

1519


how do you reference the fixed unblock file formats from cobol programs

712


What is report-item in COBOL?

711


Write the code implementing the perform … varying.

644


can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there

1905


What is a SSRANGE and NOSSRANGE?

820