š SQL, DBMS & RDBMS Explained Simply: A Beginnerās Guide to Managing Data
Updated: Jul 15, 2025
Introduction
Ever wondered how apps like Amazon, hospitals, or school systems manage huge amounts of data? The answer lies in databases and a powerful language called SQL. This blog will guide you through the basics of SQL, DBMS, RDBMS, and key database concepts ā in simple, beginner-friendly terms.

DBMS(Database Management System):
Before DBMS, data was managed using manual systemsĀ like paper records, Excel sheets, or flat files like .csvĀ or .txt. There were no rules, no structure, and everything was stored in a single table. This led to a lot of duplicate data, and searching or updating records was very difficult.
Then came DBMSĀ ā Database Management Systems ā which allowed us to store data in structured tables. But these tables were independent, meaning there was no relationshipĀ between them. So data duplication and integrity issues still existed.
DBMS (Database Management System)Ā is software that helps store, manage, and retrieve data from databases.
The concept of Database Management Systems (DBMS)Ā started in the 1960s.
Early DBMSs stored data but had no standardized query language.
Examples:
MS Access
dBase
FoxPro
In older days, SQL was used to interact with DBMSĀ , but in a more basic way.
SQL was used only for basic commandsĀ like:
CREATE TABLE
INSERT
SELECT
DELETE
Types of DBMS:
Hierarchical DBMSĀ ā Data organized like a tree
Example: IBM Information Management System (IMS)
Network DBMSĀ ā Many-to-many relationships
Example: Integrated Data Store (IDS)
Relational DBMS (RDBMS)Ā ā Uses tables and relationships (most common)
Example: MySQL, Oracle, SQL Server
Object-Oriented DBMSĀ ā Data stored as objects
Example: db4o, ObjectDB
NoSQL DBMSĀ ā Stores flexible data formats like JSON
Example: MongoDB, Cassandra
Distributed DBMSĀ ā Data spread across systems
Example: Apache Cassandra, Google Spanner
In-Memory DBMSĀ ā Fast, uses RAM for real-time access
Example: SAP HANA, VoltDB
RDBMS(Relational Database Management System):
RDBMS (Relational Database Management System)Ā is a type of DBMS that stores data in table format and supports relationships between data using keys.
Ā 1. Primary Key:
Ensures no duplicateĀ and no NULLĀ values.
Only one primary key per table.
Ā 2. Foreign Key:
Refers to the Primary KeyĀ in another table.
Used to link two tablesĀ (relationship).
Can have duplicate and NULL values.
Key Features:
Uses tables (rows and columns)
Supports primary and foreign keys
Ensures data integrity with ACID compliance
Examples:
MySQL
Oracle
PostgreSQL
SQL Server
Part | Role |
Database | š The actual containerĀ or locationĀ where data is stored (tables, rows, columns) |
DBMS | š ļø The tool/softwareĀ that helps you create and manage the database |
RDBMS | š§ An advanced DBMSĀ that supports relationshipsĀ between tables (via primary & foreign keys) |
DBMS VS RDBMS:
Feature | DBMS (Database Management System) | RDBMS (Relational Database Management System) |
Data Format | Stores data in files or simple tables | Stores data in tables with rows & columns |
Relationships | No relationships between data | Supports relationshipsĀ between tables |
Data Integrity | Limited integrity rules | Follows ACID rulesĀ for reliability |
Query Language | May not support SQL fully | Uses SQLĀ to manage data |
Multi-user Access | Limited or no support | Supports multiple usersĀ at the same time |
Data Redundancy | Higher chances of duplication | Reduces redundancy with keys |
Examples | File systems, XML | MySQL, Oracle, PostgreSQL, SQL Server |
But, What is Integrity rules and ACID properties? Let's deep dive into these topics.
Integrity rulesĀ are like traffic rules for data. They make sure that every piece of data in a database is correct, valid, and fits in the right place. This prevents errors like duplicate IDs or missing links between tables.
Rule | Description | Example |
Entity Integrity | Primary key must be unique and not null | Each student must have a unique ID |
Referential Integrity | Foreign key must match a primary key in another table | Can't enter marks for a student who doesn't exist |
Domain Integrity | Data must follow correct data type and rules | Age must be a number, not 'ABC' |
ACID propertiesĀ are like safety rules for transactions. They make sure that every database operation (like saving or transferring data) happens completely and safely ā even if something goes wrong like a system crash.
Property | Meaning | Example |
Atomicity | All steps of a transaction must succeed or none | Money transfer: both accounts update or none do |
Consistency | Keeps data valid before and after changes | Can't break rules like foreign keys |
Isolation | Transactions work separately without conflict | Two users can buy products at the same time |
Durability | Once data is saved, it remains safe | Survives power failure |
Real-World Applications of DBMS
BankingĀ ā Manage accounts and transactions
E-commerceĀ ā Product, order, and customer data
EducationĀ ā Student records, attendance, grades
HealthcareĀ ā Patient history, appointments
TelecomĀ ā Call logs, billing, user plans
TransportĀ ā Ticket booking, schedules
GovernmentĀ ā ID, tax, vehicle registration
Social MediaĀ ā Profiles, posts, messages
ERP SystemsĀ ā Inventory, HR, finance
Websites/BlogsĀ ā Posts, comments, users
What is SQL?
SQL (Structured Query Language)Ā is the language we use to interact with the database ā to create, read, update, or delete data. SQL doesnāt directly interact with the physical database ā the DBMS/RDBMS does that.
Why SQL is Popular:
Easy to learn and use
Simple syntax (uses English-like commands)
Portable across most databases
Supports querying, views, and transactions
How SQL, DBMS & RDBMS Work Together?
Layer | What it Does |
š¤ You (User) | Write SQL commands |
š¬ SQL (Language) | Sends the request (command) |
š§ DBMS/RDBMS | Understands the SQL and fetches/stores data |
š¾ Database | The actual data is stored here |
Types of SQL Commands:
a)DDL ā Data Definition Language
Used to define and manage the structureĀ of database objects (tables, schemas, etc.).
Command | Use |
CREATE | Create new table or database |
ALTER | Modify existing table (add/remove column) |
DROP | Delete table or database |
TRUNCATE | Remove all records from a table (faster than DELETE) |
RENAME | Rename a table or column |
b) DML ā Data Manipulation Language
Used to manipulate dataĀ (add, update, delete rows).
Command | Use |
INSERT | Add new data to a table |
UPDATE | Modify existing data |
DELETE | Remove data from a table |
c) Ā DQL ā Data Query Language
Used to query dataĀ from the database.
Command | Use |
SELECT | Retrieve data from one or more tables |
d) DCL ā Data Control Language
Used to control accessĀ and permissions.
Command | Use |
GRANT | Give user access to database objects |
REVOKE | Remove user access |
e) TCL ā Transaction Control Language
Used to manage transactionsĀ (groups of SQL operations).
Command | Use |
COMMIT | Save all changes made by the transaction |
ROLLBACK | Undo changes if there is an error |
SAVEPOINT | Create a save point to roll back to |
SET TRANSACTION | Set the properties of a transaction |
āPostgreSQL is the actual RDBMSĀ software we use to manage data.
We create one or more databasesĀ inside PostgreSQL to store tables.
And we use PgAdminĀ as a GUI to connect to PostgreSQL and manage everything visually.ā
Conclusion
SQL is a powerful, beginner-friendly tool used across almost every industry ā from banks and hospitals to websites and social media. Learning SQL gives you the power to understand, manage, and extract insights from data ā a valuable skill in today's tech-driven world.
š¬ Got questions or want help writing your first SQL query? Drop it in the comments below!


