Situation is this:
I have a table for staff and another one for course.
In course I will have a column called coordinator which will refer to the staff_id.
This is because some staff are coordinators and some are not, etc etc.
Staff_id is an IDENTITY hence it is auto-incrementing and I have to make sure the in the course table, it won’t follow this auto-increment.
I’m just unsure how do I implement the check constraint for this case.
If I’m understanding your requirements properly you can add a foreign key constraint to the table so that it references itself:
ADENDUM
I think I had misunderstood your requirements, I missed the part about a course table. So now I am thinking that the course table needs to link back to the staff table, in which case the command would be:
You are of course free to implement your own naming convention for constraints.