Re: Structure problem

From: RayK <keattchr_at_pissbtinternt.com>
Date: Wed, 02 Oct 2002 15:15:11 GMT
Message-ID: <Xns929BA587CE6A3raymondkeattchpisssc_at_10.0.0.4>


Jackal wrote in news:5c81527d.0210020629.24251601_at_posting.google.com:

<snip>
>
> What you are calling the Job table is JobHistory in my schema.
> The PK is (empid, jobid);
> so for eacht employee you can have diferent jobs.
> (A job has to belong to an employee)
> This is the 'real' Job table
> Attibutes StrartDate, etc should be there.
> I don't see why this data wil repeat; Each row in this table
> is a diferent a job
>
> You could try this:
> Maybe choosing other primary keys wil help to simplify things;
> we also rename JobHistory to Job,
> and CVJobHistory to CVJob
>
> *****************************************
> Employee - PK (empid)
>
> Job - PK (jobid)
> (column empid is a foreign key to Employee, required!)
>
> CV - PK (cvid)
> (column empid is a FK to Employee, required!)
>
> CVJob - PK (cvid,jobid)
> (no need of empid here then!
> empid is in the cv cvid is refering to)
> *******************************************
>
> StartDate, EndDate, Details, etc. go in de Job table
> Maybe you like this beter!?, but it's really the same
> structure.
>
> Regards,
> Carlos
>

I must thank you for showing such patience!

This structure does make much more sense to me! I have diagrammed both suggestions and viewed them side by side but this one makes far more sense!

In your suggestions the relationships form a circle from Employee. That is, the relationships from employee can be followed through the other tables back to employee. I was always taught not to have this type of structure and that is why I ended up with ;

Employee 1-8 CV 1-8 JobHistory 8-1 Job

I will change ny database to your suggestion in the morning and will let you know how I got on!

RayK Received on Wed Oct 02 2002 - 17:15:11 CEST

Original text of this message