Look for entry that does not contain another field entry

CTQE

Registered User.
Local time
Yesterday, 19:32
Joined
Feb 27, 2008
Messages
48
Hello All,

I have a table with two fields, one named Class_Name & the other Employee.

How do I create a query that defines which employee has not taken a specific class?

:confused:
 
I presume you have ID or some primary key someplace?

Something like below will give you all employees that have not taken a class.
Select *
from yourTable
where YourPrimaryKey not in (select YourPrimaryKey from yourTable where Classname = '')
 
thanks for the quick reply

I do have another table where all the employee are identified.
The primary key is the Empoyee's name.

I understand your theory but I do not know the syntax required to convey that command.

Could you assist me with that?
 
The primary key is the Empoyee's name.
NOOOOOOOOOOOOOOOOOOOOOOOOOOOO, no no no no...

Someones name CAN NEVER be a Primary key ! NO NO NO!

I strongly advice you to change this and use at the very least an autonumber as the primary key, not the name !!! :eek:


I understand your theory but I do not know the syntax required to convey that command.
Syntax was allready given?!
 

Users who are viewing this thread

Back
Top Bottom