Oracle FAQ Your Portal to the Oracle Knowledge Grid

Home -> Community -> Usenet -> comp.databases.theory -> Re: Structure problem

Re: Structure problem

From: Heinz Huber <>
Date: 04 Oct 2002 13:39:04 GMT
Message-ID: <Xns929D9F36377E4hhuberraconlinzat@>

RayK <> wrote in news:Xns9295735D5F356raymondkeattchpisssc_at_10.0.0.4:

> Can anyone help with a problem with a database structure?
> I am writing a CV database. We need the facility to store more than
> one CV for each employee (we want to tailor an employees CV depending
> on the client they are going to) So I have the following tables...
> 1 Employee
> 2 CV
> 3 Job
> An employee has many CV's. A CV is for an employee
> A CV can have many jobs on it. A job can be on many CV's
> So I created a link table between CV and Job - JobHistory. Tables are
> linked like this (1-8 denotes 1 to many)
> Employee 1-8 CV 1-8 JobHistory 8-1 Job
> I met a problem when designing a form to creat a CV. One list shows
> all the jobs done by that employee. An Add button allows jobs to be
> transferred to another list on the same form so the user can add only
> certain jobs to that CV.
> Because no EmployeeID info is in the Job table I don't know what jobs
> to display on the CV form! I hope I have explained this clearly enough
> so somebody could suggest what my structure should be like!
> It seems wrong to creat a relationship between employee and job!

It depends on what you want.

Do you want a list of all the jobs the employee has done? Then you don't need any new relation at all since you can get this via Employee -> CV -> JobHistory -> Job

Do you want a list of all the jobs the employee is capable of doing? Then you need a new link table: Employee 1-8 EmployeeJobs 8-1 Job

I suppose that Job is some abstract concept of a task. The data for the concrete Job that was part of a CV should go into JobHistory.

Heinz Received on Fri Oct 04 2002 - 08:39:04 CDT

Original text of this message