take entries of a table as criteria for a query

C

Claus Haslauer

Hi,
I'm googleing and reading all morning about this, so I might be
frustrated or I don't see the the tree in the forest - so please help! :)

I've got one table (tbl_A), that contains one field with IDs (say of
cakes at the local bakery) [tbl_A]![allCakeID]

I've got a second table (tbl_B) that contains a field with IDs of the
cakes that I hate [tbl_B]![hateID].

How can I make a query that lists the cakes-IDs which I don't hate?

So far I've got:

SELECT [tbl_A].allCakeID
FROM [tbl_A]
WHERE ((([tbl_A].allCakeID)<>[tbl_B]![hateID]));

Then the parameter-entry windows pops up.
I guess the problem is, that in the criteria of the query access cant
find the single entries..

Thanks for any help,
Claus
 
C

Claus Haslauer

Ok, found sollution (finally)

SELECT [tbl_A].*
FROM [tbl_A] LEFT JOIN [tbl_B] ON [tbl_A].allCakeID = [tbl_B].[hateID]
WHERE ((([tbl_B].ID) Is Null));


Claus Haslauer wrote:
 
Top