Network Database Model
The network model turns the tree into a graph. Many-to-many becomes possible, but the program now has to navigate a web of sets.
In plain English
It is a road map: a city can be reached by many roads, not just one parent road.
The one idea
The network model generalizes the tree into a graph: one record can participate in several sets.
It is the historical answer to many-to-many data. It also shows why navigation-based databases pushed complexity onto every application programmer.
By the end
- 01Explain records and sets in the network model.
- 02Describe owner and member records.
- 03Trace many-to-many relationships through sets.
- 04Know the costs of navigational graph access.
Records and sets
The network model stores records and connects them with sets. A set has one owner record type and one or more member record types. A member can belong to several sets, so a record can have multiple parents. This removes the hierarchical restriction and supports many-to-many relationships.
Owner: Department
Set: employs
Members: Employee
Owner: Project
Set: assigns
Members: Employee
Employee can be a member of both sets.Navigational access
Programs navigate from an owner to its members, or from a member back to its owners, using set pointers. The schema encodes the allowed paths. Access can be very fast for those paths, but the application must know the graph and the set names.
Trade-offs
The network model supports complex relationships and avoids the duplication of hierarchical many-to-many workarounds. However, schema changes can break navigation, queries are procedural, and developers must understand the physical set structure. The relational model replaced it for most general-purpose applications because declarative queries and logical independence proved more valuable.
A student in several courses
A university needs students enrolled in many courses, and courses containing many students.
Define Student and Course record types.
Each record has a stable database key.
Define an Enrollment set with Student as owner and Course as member.
A student can own many enrollment occurrences.
Define a second set with Course as owner and Student as member.
The same student participates from both directions.
ConclusionThe graph solves the shared-entity problem, but the application must know which set to traverse. The model exposes the path instead of hiding it behind a query language.
The trade-off
No free correctness.
Gain
Efficient many-to-many navigation without duplicating records.
Cost
Complex pointer structures; schema changes can break programs that know the old paths.
Verdict
A useful historical lesson in why declarative access beat manual navigation.
Recap
What to keep.
Takeaways
- +Network databases are graphs of records connected by sets.
- +A record can be a member of multiple sets, enabling many-to-many relationships.
- +Access is navigational through owner/member links.
- +Fast for known paths, brittle for changing queries.
- +The relational model traded navigation for declarative access.
Traps
- !Assuming a set is the same as a relational table.
- !Forgetting that navigation follows predefined paths.
- !Ignoring the complexity of schema evolution.
Focus
- →Draw a set with an owner and members.
- →Explain how a record can have multiple parents.
- →Compare network navigation with relational joins.
Check yourself
Before you turn the page.
What is a set in the network model?
How does the network model support many-to-many relationships?