Skip to content

System Architecture - DBMS

Database Management Systems (DBMS) are built to abstract data complexities and provide users a simplified and secure interaction layer. This tutorial explains how data is viewed at various abstraction levels, the role of schemas and instances, database languages, data models, and application interaction mechanisms. It also covers the role of a Database Administrator (DBA) and common DBMS architectures used in real-world applications.


  • Provides abstraction between data storage and user interaction.
  • Allows multiple users to access the same data with personalized views.
Abstraction of DBMS
  • Describes how data is actually stored, in forms of bits/bytes, in which file format.
  • Uses low-level structures like N-ary trees, compression, or encryption.
  • Defines the physical schema.
  • Goal: Enable efficient access to data via optimized storage strategies.
  • Describes what data is stored and the relationships among data.
  • Used by DBAs to define the logical schema.
  • Users at this level do not require knowledge of physical storage.
  • In General, when we say DB schema it refers to Logical Schema.
  • Goal: Focus on ease of use and application design.
  • Highest level of abstraction; provides different views to different users.
  • Defines subschemas relevant to specific user groups.
  • Enhances security by hiding sensitive parts of the database.
Schema Levels

ConceptDescription
InstanceData stored in the database at a specific moment
SchemaStructural design or blueprint of the database
TypesPhysical schema, Logical schema, View schema (subschemas)
  • Schema defines the data structure and changes infrequently.
  • Instances reflect the current data and change frequently.
  • Logical schema is critical for application development.
  • Physical data independence ensures schema changes don’t affect applications.

A data model is a collection of conceptual tools for describing:

  • Data
  • Relationships
  • Semantics
  • Constraints
  • Entity-Relationship (ER) Model
  • Relational Model
  • Object-Oriented Model
  • Object-Relational Model

These are used to design databases at the logical level.


LanguagePurposeExamples / Notes
DDLDefine schema & structureCREATE TABLE, ALTER, DROP
DMLQuery & manipulate dataINSERT, SELECT, DELETE, UPDATE
  • In practice, most systems use a unified language like SQL for both DDL and DML.
  • Query language is a subset of DML for data retrieval.
SELECT * FROM Students;
INSERT INTO Students VALUES (1, 'Akash', 'CSE');
UPDATE Students SET name = 'A. Halder' WHERE id = 1;
DELETE FROM Students WHERE id = 1;

Accessing Database from Application Programs

Section titled “Accessing Database from Application Programs”
  • Applications written in languages like PHP, C++, Java, JavaScript, TypeScript send queries to the DB.
  • These use APIs to send DDL/DML statements and retrieve results.
APIPlatformLanguage
ODBCMicrosoftC/C++
JDBCJava-basedJava
Drizzle/PrismaJavaScript / TypeScript basedJavaScript / TypeScript
  • Amazon may store its customer data in any-language and can use an ORM to fecth it from the DB
  • A blog System like https://akashhalder.in/blogs/explore is getting powered by this type of interface(ORM)
DB access through Node-JS App

The DBA manages and controls access to both data and DBMS operations.

  1. Schema Definition

  2. Storage & Access Method Selection

  3. Modifying Schema & Physical Organization

  4. Authorization Management

  5. Routine Maintenance

    • Backups
    • Security patching
    • Software upgrades

  • DBMS, application, and client reside on the same machine.
T1 architecture
  • Client sends queries to the DB server using APIs.
  • Business logic may reside partly on the client.
T1 architecture

T3 Architecture – Three-Tier (Used in Web Apps)

Section titled “T3 Architecture – Three-Tier (Used in Web Apps)”
  • Client → App Server → DB Server
  • App server handles business logic and prevents direct DB access.
  • Improves security, scalability, and data integrity.
T1 architecture
AdvantageDescription
ScalabilitySupports distributed application servers
Data IntegrityApp server ensures consistent transaction logic
SecurityClients have no direct access to DB → safer