> For the complete documentation index, see [llms.txt](https://wiki.nushackers.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wiki.nushackers.org/orbital/relational-database/index.md).

# Database Overview

## Database (DB)

A database is a **structured collection of data** that is organized and stored in a way that allows for efficient retrieval, management, and manipulation of the data.

## Database Management System (DBMS)

A Database Management System (DBMS) is a software that provides an interface for managing databases, either with direct user actions via its CLI/GUI, or with standardized interface used by other parts of the application.

Core functionalities of DBMS include ensuring **data integrity, security, and concurrency control**.

## Relational Database

A relational database is a type of database that organizes data into **tables**, consisting of rows and columns. Structured Query Language (SQL) is used for querying and manipulating data.

It follows the relational model, which defines relationships between tables using **keys**.

| ![Image 1](/files/JnvIpwuhVNAnO6GhrRUt) | ![Image 2](/files/PNtSxYRzQA3FiH1vfRoa) | ![Image 3](/files/0RrK9z74rFSlNX8Thb66) |
| --------------------------------------- | --------------------------------------- | --------------------------------------- |

## Non-Relational Database

A non-relational database, also known as NoSQL (Not Only SQL) provides flexible schema.

Data is arranged in various formats, such as **key-value pairs, documents, graphs, or wide-column stores**. Non-relational databases are designed to handle large amounts of unstructured or semi-structured data efficiently.

| ![Image 1](/files/B8zNNHJndfPaWQ7jV8Xb) | ![Image 2](/files/EU8Mo8K9hDaamaTNKNEs) | ![Image 3](/files/wFW1wGlHoditEQG7NXir) |
| --------------------------------------- | --------------------------------------- | --------------------------------------- |

## In Case You Are Wondering...

Each RDBMS speaks a different SQL.

They are just dialects of SQL with slightly different syntax and extensions. They all adhere to the *ANSI SQL standard* (commonly referred but not accurate) so that under most cases, same SQL statements can be used across all RDBMS without too much modification.

Non-relational DBMS are typically very different in the way they are store data, as you see from the above examples. Hence, there isn’t a standard for NoSQL.
