Unit-1 - PDF to Flipbook
Published on Sep 03, 2026
Description:
BBA 2nd Database
1 | P a g e
Unit 1: Database Concepts and Architecture Database
1. Database Management System,
2. Database Users, and Benefits of Databases;
3. Data Models, Schemas, and Instances;
4. Three-Schema Architecture and Data Independence;
5. Database Languages and Interfaces;
6. the Database System Environment;
7. Centralized and Client/Server Architectures for DBMSs;
8. Classification of Database Management Systems.
..
Unit 1: Database Concepts and Architecture
1. Database
Definition
A database is a collection of related data organized in a structured manner so that it can be
easily accessed, managed, updated, and retrieved.
Data represents facts and figures about objects, events, or entities. When data is organized
systematically for a specific purpose, it becomes a database.
Examples
• Student Information System
• Library Management System
• Banking System
• Hospital Management System
• Railway Reservation System
Characteristics of a Database
• Represents some aspect of the real world.
• Contains logically related data.
• Designed and populated with specific objectives.
• Supports multiple users.
• Allows data sharing and integration.
Example
Student_ID Name Faculty Semester
101 Ram BBA 3rd
102 Sita BBA 2nd
2. Database Management SystemBBA 2nd Database
2 | P a g e
A DBMS is software used to create, store, manage, and control access to databases.
Definition
A Database Management System (DBMS) is software that enables users to define, create,
maintain, and control access to databases.
It acts as an interface between users/applications and the database.
Examples of DBMS
• MySQL
• Oracle
• PostgreSQL
• Microsoft SQL Server
• SQLite
• MongoDB
Functions of DBMS
1. Data Storage Management
2. Data Retrieval
3. Data Update
4. Security Management
5. Backup and Recovery
6. Transaction Processing
Advantages of DBMS
• Reduces data redundancy
• Improves consistency
• Provides security
• Supports concurrent access
• Facilitates backup and recovery
• Improves data sharing
Disadvantages of DBMS
• High cost
• Complexity
• Requires skilled personnel
• Large storage requirements
3. Database Users
Different people interact with a database system in different ways.
Common database users include:BBA 2nd Database
3 | P a g e
• Database Administrator (DBA)
• Database Designers
• Application Programmers
• End Users
• System Analysts
A. Database Administrator (DBA)
The DBA is responsible for managing and controlling the entire database system.
Responsibilities
• Database installation
• User account management
• Security control
• Backup and recovery
• Performance tuning
• Database maintenance
Example
A university DBA manages student records and user permissions.
B. Database Designers
Design the structure of the database.
Responsibilities
• Identify data requirements
• Define relationships
• Create database schemas
C. Application Programmers
Develop software applications that access databases.
Example
A programmer develops a student management system using MySQL.
D. End Users
People who use database applications.
Types
1. Casual Users
Access database occasionally.
Example:
• Bank manager
2. Naive Users
Use predefined applications.
Example:
• ATM users
3. Sophisticated Users
Use advanced database tools.
Example:
• Data analysts
4. Standalone Users
Use personal databases.
Example:
• MS Access users BBA 2nd Database
4 | P a g e
4. Benefits of Databases
• Reduces data redundancy
• Improves data sharing
• Provides data security
• Maintains data consistency
• Supports backup and recovery
• Allows concurrent access
• Improves data integrity
1. Reduced Data Redundancy
Redundancy means duplication of data.
File System
Student information may be repeated in multiple files.
DBMS
Data is stored once and shared.
2. Data Consistency
Ensures the same data value throughout the system.
Example:
If a student's address changes, it is updated once.
3. Data Sharing
Multiple users can access the same database simultaneously.
4. Data Security
Unauthorized users can be restricted.
Example:
Students cannot modify examination results.
5. Data Integrity
Ensures correctness and validity of data.
Example:
Age cannot be negative.
6. Backup and Recovery
Protects data against system failures.
7. Better Decision Making
Provides accurate information for analysis.
5. Data Models
A data model describes how data is stored, organized, and related.
DefinitionBBA 2nd Database
5 | P a g e
A data model is a collection of concepts used to describe database structure and
relationships.
Types:
• Hierarchical model
• Network model
• Relational model
• Object-oriented model
• Entity-Relationship model
Types of Data Models
A. Hierarchical Data Model
Data is organized in a tree structure.
Characteristics
• Parent-child relationship
• One-to-many relationship
Example:
College
|
Department
|
Student
Advantages
• Simple structure
• Fast access
Disadvantages
• Rigid structure
• Difficult many-to-many relationships
B. Network Data Model
Data is organized as a graph.
Characteristics
• Supports many-to-many relationships
Example:
Teacher ---- Student
\ /
Course
C. Relational Data Model
Most widely used model.
Data is stored in tables (relations).
Example:
Student_ID Name
101 Ram
D. Object-Oriented Data ModelBBA 2nd Database
6 | P a g e
Stores data as objects.
Combines database and object-oriented programming concepts.
E. Entity Relationship (ER) Model
Used during database design.
Main Components:
• Entity
• Attribute
• Relationship
Example:
Student ---- Enrolls ---- Course
6. Schemas and Instances
A schema is the overall design or structure of a database.
An instance is the actual data stored in the database at a particular time.
Schema
The overall structure of a database.
Example
STUDENT
(Student_ID, Name, Faculty)
Schema rarely changes.
Instance
Actual data stored at a particular moment.
Example:
Student_ID Name
101 Ram
102 Sita
Instances change frequently.
Difference Between Schema and InstanceBBA 2nd Database
7 | P a g e
Schema Instance
Structure of database Actual data
Changes rarely Changes frequently
Blueprint Snapshot
7. Three-Schema Architecture
The three levels are:
• Internal level: physical storage of data
• Conceptual level: logical structure of the whole database
• External level: user views of the database
(American National Standards Institute, Standards Planning And Requirements Committee)
Proposed by ANSI/SPARC to separate user applications from physical database.
Conceptual framework for database management systems (DBMS) proposed in 1975.
Levels
A. External Level (View Level)
Highest level.
Shows only required data to users.
Example:
A student can view marks but not salary information.
B. Conceptual Level (Logical Level)
Describes the entire database structure.
Contains:
• Entities
• Relationships
• Constraints BBA 2nd Database
8 | P a g e
C. Internal Level (Physical Level)
Lowest level.
Describes:
• File organization
• Indexing
• Storage methods
Architecture Diagram
External Level
↓
Conceptual Level
↓
Internal Level
↓
Physical Storage
Advantages
• Data security BBA 2nd Database
9 | P a g e
• Data independence
• Multiple views
8. Data Independence
Data independence means the ability to change database structure without affecting
applications. Ability to change schema at one level without affecting higher levels.
Types:
• Physical data independence
• Logical data independence
A. Physical Data Independence
Changes in internal schema do not affect conceptual schema.
Example
Changing:
• File structure
• Indexing methods
without affecting applications.
B. Logical Data Independence
Changes in conceptual schema do not affect external views.
Example
Adding a new column:
ALTER TABLE Student
ADD Email VARCHAR(50);
Existing applications continue to work.
Comparison
Physical Logical
Easier DifficultBBA 2nd Database
10 | P a g e
Physical Logical
Internal changes Conceptual changes
Storage changes Structure changes
9. Database Languages
• DDL: Data Definition Language
Example: CREATE, ALTER, DROP
• DML: Data Manipulation Language
Example: INSERT, UPDATE, DELETE, SELECT
• DCL: Data Control Language
Example: GRANT, REVOKE
• TCL: Transaction Control Language
Example: COMMIT, ROLLBACK
A. Data Definition Language (DDL)
Used to define database structures.
Commands:
CREATE
ALTER
DROP
TRUNCATE
Example:
CREATE TABLE Student(
Student_ID INT,
Name VARCHAR(50)
);
B. Data Manipulation Language (DML)
Used to manipulate data.
Commands:
INSERT
UPDATE
DELETE
SELECT
Example: