× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Greg Weber wrote:

>I am looking for some advise.  I am working on a project, this project
>requires that I compare records from 2 files.  File A and File B.  File
>A is the primary file and File B is the secondary file.  I need to
>compare the records that are in File A to the records in File B.  What I
>am having a problem with is if there is a record in File B that is not
>in File A I need to know that.  I Was going to read File A and chain out
>to File B to see if the record exists in File B.  I am having problems
>on how to determine if there is a record in File B that is not in File
>A.  Any help would be greatly appreciated.
>
Its simple.

Ffilea    ipea e          k  disk
Ffileb    isea e          k  disk

 * filea1 = record format for filea
 * key1 = key field name for filea
ifilea1    ns    01
i                            key1     M1
 * fileb1 = record format for fileb
 * key2 = key field name for fileb (can be different field name
 *        than key field in filea as long as same length and type)
ifileb1    ns    01
i                            key2     M1

c                       select
c                       when     *in01 AND NOT *inmr
 * record in filea read with no match in fileb
c                       when     *in02 AND NOT *inmr
 * record in fileb read with no match in filea
c                       when     *in01
 * record in filea read with matching record in fileb
c                       when     *in02
 * record in fileb read with matching record in filea
c                       endsl

Matching record actually does have some value.

CAUTION:  TO AVOID BITING CRITICISM, MAKE SURE YOU DELETE THE SOURCE FOR
THIS PROGRAM WHEN YOU ARE DONE SO NOONE WILL KNOW YOU USED MATCHING RECORD
LOGIC!!!



Charlie Massoglia, Massoglia Technical Consulting, Inc.
PO Box 1065, Okemos, MI 48854, USA
517-676-9700  Fax: 517-676-1006  EMAIL: cmassoglia@voyager.net


* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* This is the Midrange System Mailing List!  To submit a new message,   *
* send your mail to "MIDRANGE-L@midrange.com".  To unsubscribe from     *
* this list send email to MAJORDOMO@midrange.com and specify            *
* 'unsubscribe MIDRANGE-L' in the body of your message.  Questions      *
* should be directed to the list owner / operator: david@midrange.com   *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.