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
What are the various section in data division and briefly explain them.
How do define dynamic array in cobol.
There are 5 fields and 1000 records in a file. Unload it into an array. Write the syntax for declaration and how will you unload it.
input 1 input2 ouput1 output2 output 3 1 re 300 1 re 200 1 re 300 3 rc 500 1 re 200 2 rr 400 1 re 300 2 rr 400 1 rc 400 3 rc 500 1 rc 400 2 rr 700 2 rr 700 5 tt 900 5 tt 900 2 inputs r in flat file and output 1 is matched records,ouptput2 is unmatched of input1,output3 is unmatched of input2! how vl u get the output files using sequential order and to check with each and every records! let me know the procedure division ?
How to change size of Initial number of records to *NOMAX for ALL PF files from perticular library, how can I do that
explain sorting techniques in cobol program?
Name the divisions, which are available in a cobol program?
In which area will you utilize 88 level items in cobol?
Have you used comp and comp-3 in your project? And how?
how do you reference the ksds vsam file formats from cobol programs
if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.
Is it possible that the redefines clause has different picture clauses compared to the one it redefined?
What are 77 levels used for?
What is amode(24), amode(31), rmode(24) and rmode(any) (applicable to only mvsesa enterprise server) ?
Difference between cobol and cobol-ii?