ch1
Chapter 1: Introduction to Database System Concepts
Overview
Authors: Silberschatz, Korth, and Sudarshan
Edition: 6th
Conditions on re-use: Check www.db-book.com
Key Topics Covered in the Chapter
The Need for Databases
Data Models
Relational Databases
Database Design
Storage Manager
Query Processing
Transaction Manager
Database System Objectives
Long-term Storage:
Support large amounts of data (hundreds of GB)
Ensure data persistence through crashes and unauthorized access protection.
User Interaction:
Facilitate querying and updating (e.g., which courses professors teach, inserting new enrollments).
Enable multiple users (hundreds or thousands) to access data concurrently.
Allow schema changes, such as adding information about teaching assistants (TAs).
Drawbacks of Direct Implementation
Implementing directly on file systems leads to several issues:
File System Limitations:
Data size restricted to less than 4GB on 32-bit machines.
Potential data loss on crashes.
Insufficient password-based security measures.
Query/Update Issues:
New queries require extensive programming and optimization efforts.
Concurrency Challenges:
Maintaining data consistency becomes problematic with multiple users.
Different users need to view data in various ways (e.g., administrators vs. students).
Schema Adaptations:
Changing files and formats requires rewriting existing applications.
Data Integrity:
Ensuring data validity across files can become cumbersome and unreliable without a structured system.
Database Management System (DBMS) Purpose
A DBMS manages a collection of interrelated data and provides a set of programs for accessing that data.
Database Applications:
Banking (transactions)
Airlines (reservations)
Universities (registration, grading)
Sales and online retail systems
Manufacturing (production, inventory)
Human resources (employee records)
Data Size:
Databases can be very large and integral to multiple aspects of life.
Applications of Database Systems
Common operations in applications include:
Adding students, instructors, and courses.
Registering students and generating class rosters.
Assigning grades and calculating GPAs.
Problems with Initial Database Applications
Data Redundancy and Inconsistency:
Multiple formats and duplications complicate data usage.
Difficulty in Accessing Data:
New tasks require new programs, leading to inefficiencies.
Data Isolation and Integrity Issues:
Maintaining relationships and constraints becomes complicated without a DBMS.
Database Transaction Management
Atomicity of Updates:
Ensures that databases remain consistent, with partial updates avoided (e.g., fund transfers must be all or nothing).
Concurrency Control:
Manages simultaneous data updates by different users to prevent inconsistencies.
Security Concerns:
DBMS allows differentiated user access to sensitive information.
Data Abstraction Levels
Physical Level:
Details how records are stored.
Logical Level:
Defines data structures and relationships (example: instructor record structure).
View Level:
Application programs hide complex data types and enable security through information concealment.
Comparison of Database Models
Relational Model:
All data stored in tables with rows and columns.
Object-Relational Data Models:
Integrate object-oriented design with relational structure for more complex data types.
Database Language Components
DML (Data Manipulation Language):
Used for querying and updating data.
DDL (Data Definition Language):
Specifies database schema.
DCL (Data Control Language):
Defines access rights and integrity constraints.
Database System Design Processes
Logical Design:
Determine the database schema, identifying attributes and their organization in relations.
Physical Design:
Determine physical storage structures and layout of data.
Methodologies for Database Design
Entity-Relationship Model:
Models the database as a collection of entities and relationships, visually represented.
Normalization Theory:
Formalizes good design practices and tests against potential issues.
Conclusion on Database Evolution
Historical context:
Evolved from magnetic tapes and hierarchical models to modern DBMS technologies.
Current Trends:
Large data warehousing, object-oriented models, and NoSQL solutions in response to big data challenges.