CompareTwoTables.mdb (intermediate)

Please consider donating $1 per sample downloaded, find out why here
Access 97 (36 KB)

This sample shows how you can programmatically compare two tables and write out the differences to a third table.

It assumes that one table (the Base) is considered to be the accurate table. The table that is being compared to the base table is called the Varying table. The results, listed in the TableDiscrepancies table are alway listed in terms of the base table.

There are two different versions, CompareTables in Module1 and CompareTables2 in Module2. The main difference is that CompareTables2 is more robust, giving you more information about what was changed and putting the information into separate fields rather than just a string.

To run this application, go to the appropriate Module, place the cursor in the "testCompare" sub routine and put the Run button.




Need Winzip?

Return to Main Page