create table PEOPLE_DEPT (
id NUMBER Primary Key,
dept VARCHAR2(100)
)
create table PEOPLE_JOBTYPE (
id NUMBER Primary Key,
jobType VARCHAR2(100)
)
create table PEOPLE_USERS (
id NUMBER Primary Key,
dateModified date,
***DO I REMOVE THIS REFERENCE? AND THE DEPT ONE?***
jobType_id NUMBER Foreign Key REFERENCES PEOPLE_JOBTYPE(id),
fname VARCHAR2(100),
lname VARCHAR2(100),
title VARCHAR2(100),
dept NUMBER Foreign Key REFERENCES PEOPLE_PEOPLE_DEPT(id),
phone VARCHAR2(50),
location VARCHAR2(200),
email VARCHAR2(100),
summary VARCHAR2(3000),
imagePath VARCHAR2(200),
link VARCHAR2(200)
)
create table PEOPLE_GROUP (
recordID NUMBER Primary Key,
user_id NUMBER Foreign Key REFERENCES PEOPLE_USERS(id)
dept_id NUMBER Foreign Key REFERENCES PEOPLE_DEPT(id)
jobType_id NUMBER Foreign Key REFERENCES PEOPLE_JOBTYPE(id)
)
So then, if they have multiple checkboxes selected for jobType and Dept, then I add them once for each jobType and once for each Dept, conceivably adding someone to the DB 8 times.
Is this right?
>No, I'm suggesting the following:
>
>GROUPS
>GroupID GroupName
>1 Family Studies
>2 Kinnesiology
>
>USERS
>UserID UserName
>1 John Burns
>2 Daniel Kessler
>
>USERGROUPS
>UserID GroupID
>1 1
>2 1
>2 2
>
>Which would mean that John Burns is in Family Studies while Daniel
>Kessler is in Family Studies and Kinnesiology. I hope that helps.
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

