hi.
Rick Schumeyer wrote:
[...]
From a business rules perspective:
Some users are not employees (like an admin user)
Some employees are not users
[...]
from my view users and employees have something in common: they are persons.
why don't create a person-table with the attributes the
I'm developing a system using Ruby on Rails (with ActiveRecord) and
postgres. (Although I think my question is still relevant for, say,
java with hibernate.)
I have two classes (tables): users and employees. A user is an account
that can logon to the system, while an employee is...umm...an
Rick Schumeyer [EMAIL PROTECTED] writes:
I can think of two ways to do this:
1) a 1-1 relationship where the user table contains a FK to the employee
table. Since not all users will be employees, the FK will sometimes be null.
In rails, the user class would belong_to employee while employee
On Fri, Mar 09, 2007 at 10:06:52 -0500,
Rick Schumeyer [EMAIL PROTECTED] wrote:
From a business rules perspective:
Some users are not employees (like an admin user)
Some employees are not users
I can think of two ways to do this:
1) a 1-1 relationship where the user table contains