I have 5 type of users:
- Super Admin
- Coordinator
- Supervisor
- Student
- External Examiner
All of them have some common attributes like ID
, name
, email
etc. I have inserted them in one table user
differentiating them with user_type
attribute.
I have also made different tables for each user like Coordinator
, Student
because each user have different attributes.
My Question is:
if I want to add a coordinator user into table, I can add it into user table with
user_type=Coordinator
but how will I link this coordinator fromuser
table into 'coordinator' table?
Can anyone provide me with PHP-MySQL code for it?