Page 1
Wink Notes
B.Tech CSE — 4th Semester
Database Management Systems
— Unit - 1 —
1. Introduction to Databases
Before the advent of databases, computer systems stored data using traditional File Processing Systems. A university might have one set of flat files for the Accounts department, another set for the Library, and a third for the Examination department. This approach led to severe, compounding issues as organizations grew.
1.1 The Problems with File Processing Systems
- Data Redundancy and Inconsistency: The exact same data (e.g., a student's address) is stored in multiple places (Accounts file, Library file). If the student moves, their address might be updated in Accounts but forgotten in Library, leading to inconsistent, contradictory data.
- Difficulty in Accessing Data: If a manager needs a new report combining data from Accounts and Examinations, a programmer must write a brand-new application program specifically for that report. There is no easy, standard way to query the data.
- Data Isolation: Data is scattered across various files, and the files might be in different formats (CSV, binary, text). Writing new applications to retrieve the appropriate data is incredibly difficult.
- Integrity Problems: Data values must satisfy specific constraints (e.g., Account Balance cannot fall below $0). In a file system, these constraints must be hard-coded into the application logic itself. Changing a constraint means finding and rewriting every single application that touches that file.
- Atomicity of Updates: If a system crashes in the middle of a complex operation (like transferring money from Account A to Account B), the file system might be left in an inconsistent state (Money deducted from A, but never added to B). It is difficult to ensure "all-or-nothing" execution.
- Concurrent Access Anomalies: If two bank clerks try to read and update the same account file at the exact same millisecond, the final balance will likely be incorrect. File systems lack robust concurrency control.
- Security Problems: Enforcing authorization (e.g., Clerk A can read salaries but not modify them, Clerk B cannot see salaries at all) is extremely difficult when data is just sitting in plain text files.
A Database Management System (DBMS) was designed specifically to solve every single one of these problems.