The main objectives of using databases are as follows:

1.   Data integration: The data in file system is stored in separate files. It is very difficult to access data stored in separate and independent files. An important objective of databases is to solve this problem. The data in database may be located at different computers physically but it is connected through data communication links. In this way, data appears centralized logically.

2.    Data integrity: Data integrity means the reliability and accuracy of data. Integrity rules are designed to keep the data consistent and correct. These rules act like a check on the incoming data. It is very important that a data base maintains the quality of the data stored in it. DBMS provides several methods to enforce integrity of the data in a database.

Enforcing data integrity ensures the quality of data in the database. For example, if an employee ID is entered as “123”, this value should not be entered again. The same ID should not be assigned to two or more employees.

3.    Data independence: Database approach provides the facility of data independence. It means that the data and the application programs are separate from each other. The user can change data storage structures and operations without changing the application programs. The user can also modify programs without reorganization of data.

Q. define database model. Describe different types of database models.

A set of rules and standards that define how the database organizes data is called database model. It also defines how users vies the organization of data.

Types of Database Models

There are three types of database models. These models are as follows:

1.    Hierarchical Model

The hierarchical model arranges records in hierarchy like an organizational chart. Each record type in this model is called a node or segment. A node represents a particular entity. The top-most node is called root. Each node is a subordinate of the node that is at the next higher level. A higher level node is called parent and lower level node is called child. A parent node can have one or many child nodes. A child node can have only one parent node. This kind of structure is often called inverted tree.


Figure 1.4: Hierarchical Model

2.   Network Model

The network model is similar to hierarchical model. The difference is that child node can have more than one parent nodes. The child nodes are represented by arrows in network model. It requires more complex diagram to represent a database. It also provides more flexibility than hierarchical model.


Figure 1.5: Network Model

3.   Relational Model

Relation model is the most commonly used database model. It is more flexible than hierarchical and network database models. The relational model consists of simple relations. A relation is a term used for table. A relation represents a particular entity. It is used to store information about the entity. The relationships are based on the data of the entities. The relationship between entities is represented by the following diagram:


Figure 1.6: relational Model