Mastering Database Management

0 of 78 lessons complete (0%)

Introduction to Databases

Types of databases (relational, NoSQL, etc.)

You don’t have access to this lesson

Please register or sign in to access the course content.

There are several types of databases designed for various purposes and requirements. Here are some primary types of databases:

Relational Databases

A relational database is a type of database management system (DBMS) that organizes data into tables, where each table consists of rows and columns. It follows the principles of the relational model, introduced by E.F. Codd in 1970, and is widely used for structuring and querying data in various applications.

  • Tables: In a relational database, data is stored in tables, each representing a specific entity or relationship. Tables are two-dimensional structures with rows (records) and columns (attributes).
  • Rows and Records: Rows, also known as records or tuples, represent individual instances of data within a table. Each row contains values corresponding to the attributes defined by the table’s columns.
  • Columns and Attributes: Columns, or attributes, define the characteristics of the data stored in a table. Examples include name, age, and address. Columns enforce a specific data type for their values.
  • Primary Key: A primary key is a unique identifier for each record in a table. It ensures that each row can be uniquely identified, and it is used to establish relationships between tables.
  • Foreign Key: A foreign key is a column or set of columns in one table that refers to the primary key of another table. It establishes a link between the two tables, reflecting relationships in the data.
  • Normalization: Normalization is the process of organizing data in a database to reduce redundancy and dependency. It involves dividing large tables into smaller ones and defining relationships between them.
  • Joins: Joins are operations that combine rows from two or more tables based on a related column between them. Common types of joins include INNER JOIN, LEFT JOIN, RIGHT JOIN, and FULL JOIN.
  • Data Integrity: Relational databases enforce data integrity through the use of primary keys, foreign keys, and constraints, ensuring accuracy and consistency.
  • Flexibility: The relational model allows for flexible querying and reporting, making it easy to retrieve and analyze data using SQL (Structured Query Language).
  • Scalability: Relational databases can scale vertically by adding more resources to a single server or horizontally by distributing data across multiple servers.
  • Normalization: Normalization helps in organizing data efficiently, reducing redundancy, and minimizing the chances of data anomalies.
  • Security: Relational databases offer robust security features, including user authentication, authorization, and encryption, to protect sensitive information.

Relational databases form the backbone of data management in various industries. Understanding the principles of tables, rows, columns, keys, and normalization is crucial for effective database design and development. The use of SQL for querying and managing relational databases provides a standardized and powerful means of interacting with structured data.

RDBMS Available

An open-source relational database management system widely used for web applications.

A powerful and open-source object-relational database system known for its extensibility and standards compliance.

A commercial RDBMS known for its reliability, scalability, and comprehensive feature set.

A relational database management system developed by Microsoft, commonly used in enterprise environments.

Non-Relational Databases

Non-relational databases, often referred to as NoSQL databases, are a category of database management systems that do not follow the traditional relational model. Unlike relational databases, which use tables with predefined schemas, non-relational databases are designed to handle unstructured or semi-structured data and provide more flexibility in data storage and retrieval.

Schema-less: Non-relational databases do not enforce a fixed schema, allowing for dynamic and flexible data structures. Each record (document, key-value pair, etc.) can have different fields.

Scalability: NoSQL databases are often designed to scale horizontally, allowing for the distribution of data across multiple nodes or servers to handle large volumes of data and traffic.

Types of NoSQL Databases: There are different types of NoSQL databases, including document-oriented, key-value stores, column-family stores, and graph databases, each suited for specific use cases.

Designed for Specific Use Cases: NoSQL databases are often chosen based on the nature of the data and the requirements of the application, allowing for efficient storage and retrieval of diverse data types.

Flexibility: Non-relational databases can handle diverse data types and evolving schemas.

Scalability: Horizontal scalability allows for distributing data across multiple nodes, accommodating growing data loads.

Performance: NoSQL databases are often optimized for specific use cases, providing high performance for certain types of queries.

Simplified Development: The flexible nature of NoSQL databases can simplify development by allowing developers to work with data in a way that aligns with the application’s needs.


  "_id": ObjectId("60f8d84a0a45b719c4380d71"),
  "title": "The Hitchhiker's Guide to the Galaxy",
  "author": "Douglas Adams",
  "genre": ["Science Fiction", "Comedy"],
  "publish_year": 1979,
  "publisher": "Pan Books",
  "ratings": {
    "goodreads": 4.2,
    "amazon": 4.5

Non-relational databases, such as MongoDB, offer a different approach to data storage and retrieval compared to traditional relational databases. They are well-suited for scenarios where data structures are dynamic, and the emphasis is on scalability and flexibility. Understanding the characteristics and use cases of non-relational databases is crucial for making informed decisions in database design.

Difference of Relational and Non-relational Databases

AspectRelational DatabasesNon-Relational Databases
Data StructureStructured, tabular format with predefined schemasVarious data models (document-oriented, key-value, etc.)
Organized into tables, rows, and columnsFlexible data storage, dynamic schemas
Follows the relational model principlesMay not enforce a fixed structure
SchemaEnforces a fixed schemaTypically schema-less or schema-flexible
Changes may require altering tablesDynamic addition of fields without affecting data
ScalabilityPrimarily scales verticallyDesigned for horizontal scalability
Adds more resources to a single serverDistributes data across multiple nodes or servers
Use CasesWell-suited for well-defined data structuresIdeal for dynamic or evolving data structures
Common in business applications, finance, etc.Suited for unstructured or semi-structured data
Query LanguageUses SQL for querying and manipulating dataQuery languages vary (e.g., MongoDB uses JSON-like)
Standardized language for relational databasesNo standardized query language for all types
Complexity & Dev SpeedCan be more complex to design and maintainOffers flexibility and speed in development
Schema changes may require careful planningWell-suited for agile development processes
ExamplesMySQL, PostgreSQL, Oracle Database, SQL ServerMongoDB (document-oriented), Redis (key-value), etc.
Difference of Relational and Non-relational Databases

Majorly we are using Relational and Non-Relational Databases.