View previous topic :: View next topic
|
Author |
Message |
noorkh
New User
Joined: 06 Mar 2006 Posts: 76 Location: Chennai
|
|
|
|
Hi,
I have following 4 fields in 2 different files. Let us call 1 file as Estimate file(Master file) and another file as Payment file(which can have duplicates).
We have sorted both the file on the following basis Claimno, Client no,
Estimate code, Cover code.
All the above mentioned fields are Alphanumeric.
Can any of you give me logic to match the estimate file records with payment file records and write down the estimate file?
For eg:
IF EST-CLAIM-NO = PYT-CLAIM-NO AND
EST-CLT-NO = PYT-CLT-NO AND
EST-EST-CDE = PYT-EST-CDE AND
EST-COV-CDE = PYT-COV-CDE
The above code can easily find out matching records.
But I need to process record by record. As Estimate file is Master file. We need to pick one record from Estimate file and need to check in payment file for all the matching records for all the above mentioned fields.
Now problem I have here is if it doesn't match which file should i read now? Estimate file or Payment file? How can i check which is greater as it is alphanumeric?
Give me a shout if you require more clarification.
Thanks,
Noor. |
|
Back to top |
|
|
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1592
|
|
Back to top |
|
|
noorkh
New User
Joined: 06 Mar 2006 Posts: 76 Location: Chennai
|
|
|
|
Hey,
Thanks for reply. I used some simple if and else to achieve my output.
I felt inspite of using Search which always search from begin to end...it is better to use IF ... else as it is sorted file.
Thanks once again.
Thanks,
Noor |
|
Back to top |
|
|
Bitneuker
CICS Moderator
Joined: 07 Nov 2005 Posts: 1104 Location: The Netherlands at Hole 19
|
|
|
|
Noorkh, you didn't understand the hint Jack gave you; we have a search function in the menu where you may search for previously posted questions (and solutions) regarding your question. |
|
Back to top |
|
|
|