DBMS Lecture - Session 2 Notes

Jul 25, 2024

DBMS Lecture Notes

Introduction

  • Speaker name: Vishwadeep Gauthi
  • Role: Channel leader and educator on Unacademy
  • Experience: 15+ years in teaching, Master's in Data Science

DBMS Architecture

Types of Architectures

  • Two-Tier Architecture
  • Three-Tier Architecture

DBMS Structure

Parts of a Database Management System

  • Physical Storage
  • Database Schema: The overall design of the database.
  • Instance: The collection of information stored in the database at a particular moment.

Data Redundancy and Consistency

  • Problem: Multiple identical data entries in different files leading to redundancy.
  • DBMS Advantage: Updates are made to a single instance, preventing inconsistency.

Accessing Data

  • Challenges in File Systems:
    • Difficulty in accessing specific data across multiple files.
    • Need for separate programs for different access queries.

Problems with File Systems

  1. Data Isolation: Different file formats make data extraction challenging.
  2. Data Integrity Issues: Applying constraints is complex with manual file management.
  3. Atomicity: Ensures transactions are completed fully or rolled back.
  4. Concurrent Access Anomalies: Risk of inconsistent data if accessed simultaneously by multiple users.
  5. Security Problems: Sensitive data may not be adequately protected in file systems.

DBMS Advantages Over File Systems

  • Efficient Data Access:
    • Simplified query writing.
  • Data Integrity via Constraints:
    • Easier implementation of data accuracy rules.
  • Atomic Transactions:
    • Ensures data remains consistent.
  • Concurrency Control:
    • Manages multiple data access requests efficiently.
  • Improved Security:
    • Restricts data access based on user roles.

Database Languages

  • DDL (Data Definition Language): Structure of the database (creating, altering tables, etc.).
  • DML (Data Manipulation Language): Managing the data within the DB (inserting, updating data).
  • Types of DML:
    • Procedural: Requires user to specify how to retrieve data.
    • Non-Procedural: User specifies only what data is needed.

Users of DBMS

  1. Naive Users: Have no knowledge of the database structure, using applications directly.
  2. Application Programmers: Write applications that interact with the database.
  3. Sophisticated Users: Write complex queries or use DB management tools.
  4. Specialized Users: Design and develop databases themselves.
  5. Database Administrators (DBA): Manage and maintain the database system.

Data Views in DBMS

  • Three Levels of Data Abstraction:
    • Physical Level: How data is physically stored.
    • Logical Level: Logical design of the data and types of tables.
    • View Level: Access points for different users based on roles.

DBMS System Architecture

  • Query Processor: Processes commands from users and translates them for the storage manager.
  • Storage Manager: Manages physical storage and retrieval of data.
  • Query Optimization: Enhances query processing efficiency.

Session Announcements

  • Upcoming session: Designing DBMS
  • Importance of working towards your career goals, especially related to GATE preparation.

Conclusion

  • Focus on continuous learning and improvement.

  • Encouragement to actively participate in sessions and share knowledge.

  • Next Session: 5:30 PM - Designing DBMS basics and ER Diagram introduction.

Thank you for attending!