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 / kamal
Hi Presannakumar,
We can't compare two files in dfsort.so u first u merge two files and using dfsort in dfsort some fields equal to none means its coming avoid the duplicates,so we can give extra xsum the particular extra record will store xsum dataset.
sync sort we can esily match.
in cobol program matcing logic program we can use and find.
read 2 file at end.
if eno = eno1
move eno to eno3
write rec
if eno > eno1
perform first-para read
write another file
if eno < eno
perform second-para read
write another file.
now the particular record presend in another file.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is redefines clause in COBOL?
What are all the divisions of a COBOL program?
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?
IF I mention stop run in CICS what happens?
I have File 1 occurs 5 times with Employee-ID,Employee-Name,Employee-Dept (EEE and MECH). I have File 2 occurs 10 times with Employee-ID,Employee-Name,Employee-Dept (EEE,CIVIL,CHEMICAL and MECH). In FIle 1 and FIle 2 , for matching Employee-DEPT (Only MECH) , we need to move entire records from file1 to file 2. We should not use 2D array. Your help is needed here.
If you are current on the owner of a set, what is the difference between obtain next and obtain first?
What is the difference between a binary search and a sequential search? What are the pertinent cobol commands?
Can we redefine the field of x(200) to less than 200?
) How do u handle errors in BMS macro
What is amode(24), amode(31), rmode(24) and rmode(any) (applicable to only mvsesa enterprise server) ?
Write the code implementing the perform … varying.
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.
What is the LINKAGE SECTION used in COBOL?
How you can read the file from bottom?
What is the usage of comp fields in cobol?