Database Fundamentals: Comparing Relational, Hierarchical, and Network Models
Classified in Computers
Written on in
English with a size of 3.35 KB
1. Data Models and Conceptual Schemes
The conceptual scheme within the ANSI/X3/SPARC framework aims to define the data and the relationships between them that will be computerized in a particular organization, subsequently translating this into a canonical schema. The primary challenge is defining the set of entities to be stored in the database (DB), a task dependent solely on the Database Administrator (DBA).
Recall the three conceptual models, often called semantic models:
- MER (Entity-Relationship Model)
- Binary Model
- RMT (Semantic Model)
Once the conceptual design is complete, the process moves to the logical design or definition of the canonical schema. This translation process is performed using logic models, also known as data models. The most commonly used are:
- Relational Model
- Hierarchical Model
- Network Model
We will now examine the features of these three models, illustrated with examples.
2. The Relational Model
Information in this model represents entities and connections between them using relations (which take the form of tables). These tables contain standardized information.
- The rows are called tuples. Each tuple is uniquely identified in a table; therefore, there cannot be two identical tuples in a table.
- The columns are called attributes.
Attributes are assigned to a domain, which is the set of possible values for that attribute. For example, in the domain of 'Cities in Granada Province', 'Guadix' may be one of the possible values.
The key is an attribute or set of attributes that uniquely defines each tuple in the table. A key can never contain null values. Crucially, tables communicate with each other through their keys.
3. The Hierarchical Model
Information is represented by records (nodes) structured as a tree structure. It has an initial node called the root, and branches are implemented using pointers between records.
This model is more complex than the relational model due to the following limitations:
- It enforces a strict parent-child relationship (one-to-many).
- A child node cannot exist without a parent, complicating deletion and insertion operations.
- Updates must be propagated across all branches containing the node in question, making the process difficult and lengthy.
- It cannot directly map many-to-many relationships, as each child can only have one parent.
4. The Network Model
Information is represented by records and the linkages between them. Records can have any number of parents and children, thus allowing many-to-many correspondences.
Relationships between records are established via special registers called connectors, which may possess attributes (e.g., the 'date of repair' attribute shown in the example on page 6).
While the structure is more homogeneous than the hierarchical model, operations remain more complicated than in the relational model. However, deletions are relatively easy, requiring only the update of corresponding pointers.