I am trying to write a simple query.
Example:
The citizenid is also a primary key in a Citizen table. If this is not NULL then I would like to be able to return a firstname, and lastname from the citizen table (I really don't care anything about returning the citizenid - just the names). Can someone help me here? Thanks.
Example:
Code:
select animalid, citizenid from animal
where cageid = 4