comparing two tables

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to comparing two tables.
The results to be a side by side comparisions of each record from the two dbs
If the record in db-1 does not have a match in db-2, then db-2 will have a null field for that record, and the same should apply in db-2 if it has no match with db-1
have tried the query wizard and the union and not getting the results that I am looking for

ADAK
 
I would like to comparing two tables.
The results to be a side by side comparisions of each record from the two dbs.
If the record in db-1 does not have a match in db-2, then db-2 will have a null field for that record, and the same should apply in db-2 if it has no match with db-1.
have tried the query wizard and the union and not getting the results that I am looking for.
This is called a "Full Outer Join" query which is, unfortunately, not
supported directly in Access.

To get around the problem, you need *three* queries. First create a
Query joining db1 to db2 (by the appropriate linking field), select
the join line in the query grid, and choose Option 2 - "Show all items
in db1 and matching records in db2". Save this as qryLeft.

Now create another similar query using Option 3, the Right Outer Join.
Save it as qryRight.

Finally, create a UNION query

SELECT * FROM qryLeft
UNION
SELECT * FROM qryRight;
 
Back
Top