B
BruceM
I tried sending Part 2, but still NG. Here is half of Part 2.
Finally! I did something right!
....and then hope was dashed. :-(
Whoa;*what*?! <trying hard not to cry> I needed this explanation because
some things I was doing w/o really understanding why; simple because someone
said do this and then I would read a post that said no, do this, and the
book
would say something different. In tblKeyEmployees, I have a combo PK. That
was one of the original tables I had and yet I don't do the same thing here.
There it is. What I was inadequately trying to explain earlier. I can see
this is where I'm going to get into trouble because I don't really
understand
how you would look at that and *know* it means the same title assigned to
the
same employee over and over. I'm going to have to get a handle on this; more
homework.
Nor do I want to; I have enough trouble already.
....zzzz...zzzzz...huh?...what?!...I'm awake, I'm awake! (Besides I slid off
Well, maybe not for you...
I apologize to you now, Beetle, for the confusion because in my earlier post
I stated, " The other problem I had was somethng you mentioned earlier in
your sentence "..to help keep track of things." I was having trouble
tracking
what was happening; a situation that was not helped by some of the table
names I used (too many tables with the word Employee in it) and the fact
that
I kept adding notes and comments to my diagram so that I couldn't see
anything. I had spun off School Data from the employee table like we
discussed, but I had also put Emergency Info into a seperate table too.
One of those tables with the word Employee in it was tblEmpSubjects. I don't
know why I dropped it.
I'm almost afraid to ask because I think I should have this down since
you've already explained but, "describe a persons role within the dept.?"
Wouldn't that info be in tblEmpDept? Let me think about this some more. If I
read it over and over; it will come.
Now, as I said previously, the "many" side table holds the foreign key.
So, in this case, the junction table holds two FK's, which you have
done correctly in your junction table.
Finally! I did something right!
Where you went wrong is by putting EmpTitleID in tblEmployees as a FK.
....and then hope was dashed. :-(
EmpTitleID does not need to exist in *either* table.
Whoa;*what*?! <trying hard not to cry> I needed this explanation because
some things I was doing w/o really understanding why; simple because someone
said do this and then I would read a post that said no, do this, and the
book
would say something different. In tblKeyEmployees, I have a combo PK. That
was one of the original tables I had and yet I don't do the same thing here.
there is nothing to prevent the same title being assigned to the same
employee many times over.
There it is. What I was inadequately trying to explain earlier. I can see
this is where I'm going to get into trouble because I don't really
understand
how you would look at that and *know* it means the same title assigned to
the
same employee over and over. I'm going to have to get a handle on this; more
homework.
It is not good practice to introduce unnecessary elements into your db.
Nor do I want to; I have enough trouble already.
Still awake?..........Hello?........ Pick your head up off that desk.
Sleep
on
your own time, dammit! ;-)
....zzzz...zzzzz...huh?...what?!...I'm awake, I'm awake! (Besides I slid off
the chair and onto the floor 5 minutes ago said:...you have two separate M:M relationships that you need to keep track of.
Don't worry, it's not as complicated as it may sound at first.
Well, maybe not for you...
[quoted text clipped - 26 lines]tblEmployees M:M tblDepartments
EmpID (FK to tblEmployees and first part of PK - LI number)
SubjID (FK to tblSubjects and second part of PK - LI number)
I apologize to you now, Beetle, for the confusion because in my earlier post
I stated, " The other problem I had was somethng you mentioned earlier in
your sentence "..to help keep track of things." I was having trouble
tracking
what was happening; a situation that was not helped by some of the table
names I used (too many tables with the word Employee in it) and the fact
that
I kept adding notes and comments to my diagram so that I couldn't see
anything. I had spun off School Data from the employee table like we
discussed, but I had also put Emergency Info into a seperate table too.
One of those tables with the word Employee in it was tblEmpSubjects. I don't
know why I dropped it.
So in essence, your Subjects table has evolved. It is not just a way
to track subjects that are taught. Rather, it is a way to describe a
persons role within a Department.
I'm almost afraid to ask because I think I should have this down since
you've already explained but, "describe a persons role within the dept.?"
Wouldn't that info be in tblEmpDept? Let me think about this some more. If I
read it over and over; it will come.