I have a File that has duplicate records. I need only those records that occur more than
thrice.?
Answer Posted / harsha
1 Sort the file on any key
2 Read file sequentially. While reading, store the record
in a working storage temporary variable and add count
counter variable.
3 Every time you read record, compare it with temporary
variable. if it is same increase counter otherwise reset
counter.
4 When counter become greater than three, write record to
an outfile.
Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
How to know whether the module is dynamical or statistical?
input= ,,,, mainframe training ,,, hyderabad .... location.... output1=$ mainframe training in hyderabad location$ output2=**** mainframe training in hyderabad location ****. In this pgn when we give input considering the spaces the output is displayed in this format.Like in the place of ,,,, $ should be displayed likewise.So please helpmeout.
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
What is static and dynamic call in cobol?
What is inspect in cobol ?
How to remove 2 duplicate records and copy only one using job control language?
What is the utilization of copybook in cobol?
What happens when we move a comp-3 field to an edited (say z (9). Zz-)?
what is search and searchall?what is the diffrence between them?give an best example?
What is the difference between a binary search and a sequential search what are the pertinent cobol?
How do you reference the fixed block file formats from cobol programs
What is the difference between goback, stop run and exit program in cobol?
Explain what you understand by passing by value.
what is the difference between COBOL2 AND COBOL390?
Explain about different table spaces.