Yes and No.
You could include all seven tables and do a standard inner join on the
Claims tracking number. That will show you where any claims number that
is in all seven tables. Or if you are interested in just three tables
then just build a query joining the three table on the claims number.
OR try a UNION query as the base query
SELECT "TableA" as TableName, [ClaimsNumber]
FROM TableA
UNION
SELECT "TableB" as TableName, [ClaimsNumber]
FROM TableB
UNION
....
UNION "TableG" as TableName, [ClaimsNumber]
FROM TableG
Now you can use that saved query to identify which tables have the claim
number.
For instance, to get claim numbers that are in TableA, TableB, and
TableC, the query would look like:
SELECT [ClaimsNumber]
FROM TheUnionQuery
WHERE TableName in ("TableA","TableB","TableC")
GROUP BY [ClaimsNumber]
HAVING COUNT(*) = 3
In all tables except TableC.
SELECT [ClaimsNumber]
FROM TheUnionQuery
WHERE TableName <> "TableC"
GROUP BY [ClaimsNumber]
HAVING COUNT(*) = 6
'====================================================
John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County
'====================================================
I am trying to write a query that will show me duplicate information from one
field across seven different tables.
Example:
The Claims Tracking Number field from Table A222 matches Claims Tracking
Number from Table A333 and A444.
Is this possible?