KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
One table could contain different "types" of records (employees, cars, cell-phones). To identify type of record I have column type : id type name 1 car Ford 2 car Toyota 3 phone motorola 4 employee Jack 5 employee Aneesh 6 phone Nokia 7 phone Motorola … … … Or there could be different tables for each type: Employees id name 1 Jack 2 Aneesh … … Cars id name 1 Ford 2 Toyota … … Phones id name 1 Nokia 2 Motorola … … These could have foreign key references from other tables. If each table had different columns you can't have that in the same table, so option 1 is ruled out unless all columns that are not common are nullable. But if different entities have similar columns, what is the better design? What are arguments for and against?
Tags (comma-separated)
Save Edits
Cancel