Hello, I'm learning normalization and I wonder if I'm doing this right, and does this database need 3NF:
Un-normalized
1NFCode:DEPARTMENT +-------------------------------------------------------------------------------+ | Dname | Dnumber | Dmgr_ssn | Dlocations | |-------------------------------------------------------------------------------+ | Research | 5 | 333445555 | { Bellaire, Sugarland, Houston } | |-------------------------------------------------------------------------------+ | Administration | 4 | 987654321 | { Stafford } | |-------------------------------------------------------------------------------+ | Headquarters | 1 | 888665555 | { Houston } | +-------------------------------------------------------------------------------+
2NFCode:DEPARTMENT +--------------------------------------------------------+ | Dname | Dnumber | Dmgr_ssn | Dlocation | |--------------------------------------------------------| | Research | 5 | 333445555 | Bellaire | |--------------------------------------------------------| | Research | 5 | 333445555 | Sugarland | |--------------------------------------------------------| | Research | 5 | 333445555 | Houston | |--------------------------------------------------------| | Administration | 4 | 987654321 | Stafford | |--------------------------------------------------------| | Headquarters | 1 | 888665555 | Houston | +--------------------------------------------------------+
Code:DEPARTMENT +------------------------------------------+ | Dname | Dnumber | Dmgr_ssn | |------------------------------------------| | Research | 5 | 333445555 | |------------------------------------------| | Administration | 4 | 987654321 | |------------------------------------------| | Headquarters | 1 | 888665555 | +------------------------------------------+ LOCATION_MAP +-----------------+ | Dnumber | LocID | |-----------------| | 5 | 1 | |-----------------| | 5 | 2 | |-----------------| | 5 | 3 | |-----------------| | 4 | 4 | |-----------------| | 1 | 3 | +-----------------+ LOCATIONS +----------------------------+ | LocID | Location | |----------------------------| | 1 | Bellaire | |----------------------------| | 2 | Sugarland | |----------------------------| | 3 | Houston | |----------------------------| | 4 | Stafford | +----------------------------+




Reply With Quote
