View previous topic :: View next topic
|
Author |
Message |
srinivas_cog
New User
Joined: 05 Jun 2008 Posts: 17 Location: chennai
|
|
|
|
Hi,
i want to compare each record from file A to all the records from file B, if not matched, want to write the details of the record from file A.
I want to write it in EAZYTRIEVE,Could you please suggest me.
Thanks |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Do you have "keys" to match or are you trying to compare the entire record?
Please post an example of the data in your input files and what you want as output from that input. |
|
Back to top |
|
|
srinivas_cog
New User
Joined: 05 Jun 2008 Posts: 17 Location: chennai
|
|
|
|
I have the ket to compare..
My requirement is :
fileA : KEY HCNNO
fileB : KEY HCNNO
I want to compare the files and if not matching i want to write the record from fileA. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
First sort both files by the "key".
Next, code a 2-file match/merge or use the matching capability of easytrieve (ther are multiple previous posts in the forum).
If you do not know how to write a 2-file match/merge, there is a "Sticky" near the top of the COBOL section of the forum that you can use as pseudo-code. Or, you can simply download the sample code and use it. |
|
Back to top |
|
|
chandrarkar
New User
Joined: 27 May 2008 Posts: 24 Location: india
|
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
I would recommend using DFSORT for this, and the topic is well discussed in that forum with good examples too. |
|
Back to top |
|
|
|