What are the Type of Databases? | Types of Databases
In this article, we'll study the various types of databases.
A database is a collection of logically related data in a systematic manner such that various requirements of a user can be met i.e. the retrieval of data, modification of data, and performing various other operations on the data. A database is managed by a database management system (DBMS). A database management system is a software (i.e. a set of programs) to manage the database that enables the user to store, update, or access the data as per requirements.
Various types of Databases are as follows:-
- Hierarchical Databases
- Network Databases
- Relational Databases
- Object-oriented Databases
- ER model Databases
- NoSQL Databases
- Graph Databases
- Document oriented Databases
HIERARCHICAL DATABASES
- In Hierarchical Databases, records are arranged in a hierarchy like an organizational chart. The nodes are connected through links that represent a relation. Each record type in this model is called a node or a segment. A node represents a specific entity.
- The topmost node is called the root. Each node is a subordinate of the node at a higher level.
- The hierarchical Database model follows a parent-child relationship and it represents a tree structure.
- A higher level node is called the parent and a lower level node is called a child. A parent can have one or more child nodes but a child node can have one and only one parent.
- The most popular hierarchical database was an Information Management System (IMS)
ADVANTAGES
- Referential Integrity is always maintained in a hierarchical model i.e. changes made in the parent tables are automatically updated in a child table. Also, it is conceptually simple due to the parent-child relationship in the organization.
DISADVANTAGES
- The hierarchical model lacks structural independence. It also does not support MANY TO MANY relationships. As only ONE TO MANY relationships is supported, this increases the redundancy in the data which leads to the retrieval of inaccurate data.
NETWORK DATABASES
- Network Data model is a progression of the hierarchical data model. It was actually designed to address the drawbacks of the hierarchical data model. It helps to address MANY TO MANY relationships that were not supported in the hierarchical data model.
- The network data model allows a child node to have more than one parent. As possessing multiple child nodes was possible in the previous data model too but the network data model even provides the functionality of possessing multiple parent nodes.
- The network data model produces a web-like structure interlinking multiple nodes.
- Some well-known examples are the Integrated Data Store (IDS), Univac DMS-1100, Raima Database Manager, etc.
ADVANTAGES
- Network Databases provides flexibility in accessing databases by providing M: M relationship i.e. MANY TO MANY relationships. Moreover, the network model promotes data integrity thereby producing accurate and complete data.
DISADVANTAGES
- The structure of the network model is quite complicated making it difficult to handle, maintain, and implement the data. Therefore, it can lead to operational anomalies because of the requirement of a large number of pointer adjustments for the insertion, deletion, and updating of the records.
RELATIONAL DATABASES
- In the relational data model, data is stored or represented in the form of TABLES i.e. relations. It can even be said that the data is structured in the form of tables. The Relational Data model was proposed by E.F Codd of IBM.
- A relation consists of rows and columns where rows are termed as TUPLES and columns are termed as ATTRIBUTES. Every relation consists of a domain i.e. a pool of values from which the actual values in the columns are appearing.
- Relational databases define the degree and cardinality of the relations where degree represents the number of columns and cardinality represents the number of tuples respectively in a relation
- Some popular relational database management systems are SQL Server, DB2, Microsoft Access, etc.
NAME |
ROLL NO. |
DEPARTMENT |
PHONE NUMBER |
RASHMI |
153 |
ELECTRICAL |
9876534210 |
REEMA |
154 |
ELECTRICAL |
9734678921 |
RHEA |
155 |
ELECTRICAL |
8745346575 |
ADVANTAGES
- Relational Databases limits redundancy and replication of data offering better data integrity.
- The presence of a very powerful query capability of relational database management systems is responsible for the immense popularity of relational databases. The structured query language eases the database operations to a greater extent.
DISADVANTAGES
- Although the relational data model offers a large number of advantages and its benefits outweigh the limitations but a serious problem with relational databases is that this database can sometimes result in the slow extraction of the data.
OBJECT-ORIENTED DATABASES
- In object-oriented databases, data is stored or represented in the form of objects and classes. It is based on the principles of object-oriented programming. It is an alternative for the relational data model and can be used at its place.
- The object-oriented data model is termed as HYBRID APPLICATION as it is produced by combining the properties of the relational data model and object-oriented principles.
- The concepts like Inheritance, Polymorphism, and Encapsulation from OOPs and the properties like Integrity, Concurrency, and Query Processing from relational models make up the Object-Oriented Databases.
- In this data model, all the entities are represented as objects and these objects possess their own properties (state) and methods (behavior).
- Examples of Object-oriented databases are InterSystems Cache, Versant Object Database, ObjectStore, etc.
ADVANTAGES
- Object-oriented databases can handle large collections of complex data including user-defined data types. Also, data relationships are expressive.
- These databases offer version control for evolving classes and projects.
DISADVANTAGES
- Not many programming languages support object-oriented databases. Also, object-oriented databases are difficult to learn for non-programmers.
ER MODEL DATABASES
- Entity-Relationship Model databases are used for the logical representation of data. They are used to provide a conceptual view of the data. They involve designing a diagram or a structure according to the architecture of the project for the implementation of the database.
- The ER model is composed of entity and relationship where the entity is any object which has physical existence and the association between two or more entities is termed as a relationship.
- ER model involves the visual representation of data which describes how the objects are related to each other.
- This model includes the attributes which are the properties defining the entity type. There are a variety of attributes that involve varying functionalities. The types of attributes include key attributes, composite attributes, multivalued attributes, and derived attributes.
NoSQL DATABASES
- The NoSQL databases rose to overcome the limitations of the relational databases mainly focussing on high operational speed and flexibility in storing the data. These databases have been mostly funded by big companies like Amazon, Google, and Facebook who first and foremost felt that there should be a database that offers high transactional speed and flexibility of data.
- In NoSQL databases, the data is structured and stored in free form formats. These databases do not involve the storing of data in relation but instead include distinct types of schemas like in the form of graphs, documents, or key-value structures.
- The four major types of NoSQL databases are Document oriented databases, Graph databases, Key-value databases, and Wide column databases.
GRAPH DATABASES
- Graph databases are the NoSQL Databases that use the graph model to represent the relationship between entities or objects. Here the entities are represented as vertices and the relationships between entities are represented by edges.
- These databases utilize graph structures made up of nodes, edges, and vertices for the queries to efficiently store and represent data in a way that prioritizes representation, discoverability, and maintainability of data relationships.
- These databases don’t need the relationships to be explicitly modeled.
- Examples of graph databases- Neo4j, JanusGraph, MarkLogic, etc.
DOCUMENT ORIENTED DATABASES
- The document-oriented databases contain documents as the basic unit of the databases. Documents are gathered together in collections within the database.
- In this data model, data objects are stored as documents such that each document stores our data and enables us to update that data or delete it. Instead of columns with names and data types, we describe the data in the document and provide a value for that description.
- Document databases are essentially used for blogs and websites content management, E-Commerce applications, event logging, web analytics, and real-time analytics, and many more.
- The most well-known document databases are BaseX, CouchDB, MongoDB, SimpleDB, etc.
ADVANTAGES
- An important advantage of document-oriented databases is that they are schema-free unlike the relational databases where every table has a schema that defines the rows and columns. Whereas in this model every document can be structured differently.
DISADVANTAGES
- Document oriented databases offer less flexible queries for e.g. MongoDB does not support joins and provides limited data size for the document.