Here we go again...
I have two tables with similar info. Neither table has a primary key believe it or not. I need all the people from Table1 who aren't in Table2. I'm trying to use last name as a key but oh my head......Any suggestions would be helpful.
Do you have table and field names? What constitutes a unique "people"?
One generic method would be:
SELECT *
FROM Table1
WHERE [LastName] not in (SELECT [LastName] FROM table2);
This is all destined for failure unless you can identify unique "people".
Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
Thank you both. The tables are essentially the same. There is no way to tell who is who unless I use a concatenated key. I have first and last names plus their addresses. I was thinking of creating a composite key of their first and last name. I need to know who is in table1 but not in Table2. Thank you both so very much. I really and truly appreicate your input....
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.