Hit enter to search or ESC to close
Underlying structure of the database is called as data model. It is a collection of conceptual tools for describing data, data relationships, data semantics and consistency constraints. Data models define how data is connected to each other and how they are processed and stored inside the system.
Types of data models are:
1. Entity Relationship Model
The entity relationship (E-R) model consists of a collection of basic objects, called entities and of relationships among these entities.
An entity can be real world object, either animate or inanimate, that can be easily identifiable. For example, in a school database, students, teachers, classes and courses offered can be considered as entities. Entities are represented by means of rectangles.
A relationship is an association among several entities. For example an employee works at a department, a student enrolls in a course. Here, works at and enrolls are called relationship. Relationships are represented by diamond-shaped box.
Entities are represented by means of their properties, called attributes. All attributes have values. For example, a student entity may have name, class, and age as attributes. Attributes are represented by means of ellipses. Every ellipse represents one attribute and is directly connected to its entity (rectangle).
The ER Model can be diagrammatically represented as follows:
Example of ER model
Let us consider an ER model for Banking system consisting of customers and accounts. The diagram shown below indicates that there are two entity sets, customer and account with attributes customer name, address, account no. and balance. In the diagram there is also a depositor between customer and account.
Advantages of ER model
2. Relational Model
The relational database was invented by E. F. Codd at IBM in 1970.The relational model represents data and relationships among data by a collection of tables, each of which has a number of columns with unique names. Relational data model is used widely around the world for data storage and processing. This model is simple and it has all the properties and capabilities required to process data with storage efficiency.
For example the following figure shows a relational database showing customers and their accounts. The customer Nina has two accounts with Rs. 50000 and 30000 balance.
Table Name: Customer
Table Name : Account info
About the author
Your email address will not be published. Required fields are marked *
Save my name, email, and website in this browser for the next time I comment.
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.