If there are two files one with 100 records and other with
101 records. we have to find out the one record that is the
odd man out . What are the steps to do it

Answer Posted / rajendran

Append 1 to the first file to the first position
Append 2 to the second file to the first position

Now SORT both the file records with option to sum on the
1st character.

at last the odd man record will be the one whose first
character would be "2" for all other it will be "3".

Please let me know if I went wrong somewhere.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do define dynamic array in cobol.

673


Can we change the password using ALTER? anyone tried and changed?

1552


What the difference is between continue and next sentence?

665


Which mode is used to operate the sequential file?

671


1.Is it possible to move the data from 99.99 to 99v99? 2.What is the CICS-vsam Compilation process? 3.In My GDG 5 generation will be there GDG3 got an abend what will happen? 4.In my GDG first generation is +1 And I want to add the new generation what will happen previous generation? 5.How can you give the PIC clause below conditions A). s9 (reddy), B). s9 (5) occurs 5 times? 6.How override the proc from a particular step? and what is symbolic and override Procs?

5379






How do define dynamic array in cobol. how do you define single dimensional array and multidimensional array in your cobol?

710


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?

897


How did the release of cobol/370 version 1.3 improve the performance of release 1.1?

645


What do you understand by psb and acb?

668


How to fetch 1000 error records from VSAM file(Eg: 1000000 records present) while getting SOC7 abend ?

1950


What is an in line perform? When would you use it? Anything else you wish to say about it.

649


A table has two indexes defined. Which one will be used by the SEARCH?

759


Differentiate between structured cobol programming and object-oriented cobol programming.

669


How to use the same COBOL program in Batch and CICS on lines? explain with an example

1914


What is the difference between Global and External Variables?

666