Help designing a relationship.
Posted by: Nauolin Molina
Date: February 11, 2008 02:11AM

Hi all.

I'm practicing with MySql and trying to figure out how to solve a subclasses problem. Maybe it's the most common and classic example of specialization. I have a table that lists all employees in a company. But the employees could be any of 2 types: full time employees or partial time employees. Each type with different attributes.
It's so obvious that the use of one table with all the attributes is the worst solution. In theory I should use 3 tables, one for the common attributes of all employees and two for each type of employee.
My question is: how to build the correct relationships between the tables?

For your help, a thousand thanks.

Options: ReplyQuote


Subject
Written By
Posted
Help designing a relationship.
February 11, 2008 02:11AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.