0% found this document useful (0 votes)
26 views

DBMS - Lecture 1

The document provides information about a database management system course including: 1) The instructor details and contact information 2) An overview of topics to be covered in the course like conceptual modeling, relational data model, SQL, and transaction processing 3) The objectives of the course which are to describe fundamental DBMS concepts, teach conceptual and logical database design, and introduce object-relational systems

Uploaded by

sohaibislam202
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views

DBMS - Lecture 1

The document provides information about a database management system course including: 1) The instructor details and contact information 2) An overview of topics to be covered in the course like conceptual modeling, relational data model, SQL, and transaction processing 3) The objectives of the course which are to describe fundamental DBMS concepts, teach conceptual and logical database design, and introduce object-relational systems

Uploaded by

sohaibislam202
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 35

1

DATABASE MANAGEMENT
SYSTEM

Course Code: CSC 433


Course Instructor
Md. Alamin Talukder
Senior Lecturer
Department of Computer Science and Engineering
International University of Business Agriculture and Technology

01/22/2024
Instructor Details
2

 Name: Md. Alamin Talukder


 Position: Senior Lecturer
 Room # 522
 Telephone Ext # 520
 Mail: [email protected]
 Contact Number: 01608891643 (Whatsapp)

01/22/2024
Course Catalog
3

Evolution of database management systems


Entity Relationship Modeling and Design (Conceptual Modeling)
Relational Data Model and Relational Algebra (Logical Modeling)
Structured Query Language (Physical Modeling)

Transaction Processing and Concurrency Control


Database System Architectures and query optimization techniques

 Legal and Ethical Aspects of Database Management

01/22/2024
Course Objectives
4

The course will provide the description of databases, their typical users, DBMS
concepts, terminology, and architecture,
The concepts of the Entity-Relationship (ER) model, illustrate conceptual database

design, data abstraction and semantic data modeling concepts, and extends the ER model
to incorporate these ideas, leading to the enhanced-ER data model and EER diagrams,
The basic concepts necessary for a good understanding of databases design and

implementation,
The conceptual modeling techniques used in database systems, the relational data model

and its integrity constraints and update operations, and


The operations of the relational algebra and give a comprehensive introduction to

object-relational systems.

01/22/2024
Course Outcome
5

CO1 Describe the fundamental concept of relational database management system

CO2 Identify the modules, features and entities along with the relationships of a
software system
CO3 Analyze a system and normalize for implementation and applying SQL for data
manipulation.

01/22/2024
Study Materials
6

 Text Book:
 Fundamental of Database System by Ramez Elmasri 7th Edition

 Reference Books:
 Database System Concept – Silberschatz−Korth−Sudarshan 6th Edition
 Database Management Systems – Ramkrishnan and Gehrke 3rd Edition

01/22/2024
Consultation Hour
7

DAY SECTIO TIME Room


N
1008
Monday Q 9.35AM – 10.35AM
Tuesday Q 8.30AM – 9.30AM 508
9.35AM –10.35AM

01/22/2024
Introduction
8

 Data:
 Definition: Data refers to raw facts, figures, symbols, or information that can be processed to gain insights or
knowledge.
 It can take various forms, including text, numbers, images, audio, video, etc. Data is the foundation for generating
information.
 Database:
 Definition: A database is a structured collection of data that is organized and stored in a way that allows for efficient
retrieval, updating, and management.
 Databases can be as simple as a single file or complex systems with multiple interconnected components. They are
designed to store and organize data to facilitate easy access and manipulation.
 Database Management System (DBMS):
 Definition: A Database Management System (DBMS) is software that provides an interface for interacting with
databases.
 It is a set of programs or software tools that allows users to define, create, manage, and manipulate databases. The
primary purpose of a DBMS is to ensure the efficient and secure storage, retrieval, and management of data. It acts
as an intermediary between the user and the database, handling tasks such as data definition, data manipulation, and
data security. 01/22/2024
What is DBMS?
9

 A Database Management System (DBMS) is software that provides


an interface for interacting with databases.
 It is a set of programs that allows users to store, modify, and extract
information from a database.
 The primary purpose of a DBMS is to manage the data efficiently and
ensure its integrity and security.
 A database is a structured collection of data organized in a way that
facilitates efficient retrieval, updating, and management of the data.

01/22/2024
A database that stores student and course information
10

Database

01/22/2024
Key features of a DBMS
11

 Data Definition Language (DDL): Allows the definition of the database structure,
specifying data types, relationships, and constraints.
 Data Manipulation Language (DML): Enables users to interact with the data, including
querying, updating, and deleting records.
 Transaction Management: Ensures the integrity of the database by providing features like
ACID properties (Atomicity, Consistency, Isolation, Durability) to handle transactions.
 Concurrency Control: Manages access to the database by multiple users to prevent
conflicts and ensure data consistency.
 Data Security: Provides mechanisms for user authentication and authorization to control
access to the database.
 Backup and Recovery: Offers tools to create backups and restore the database in case of
data loss or corruption.
01/22/2024
ACID Properties in DBMS
12

01/22/2024
ACID Properties in DBMS
13

 The ACID properties are a set of characteristics that guarantee the reliability and
consistency of database transactions. These properties are fundamental to maintaining
the integrity of data in a database system.
 Atomicity:
 Definition: Atomicity ensures that a transaction is treated as a single, indivisible unit of work.
 Implication: Either all the operations within a transaction are executed, or none are. If any part of the
transaction fails, the entire transaction is rolled back to its previous state, ensuring that the database
remains in a consistent state.
 Consistency:
 Definition: Consistency ensures that a transaction brings the database from one valid state to another.
 Implication: The execution of a transaction should adhere to all integrity constraints defined in the
database. If the database is in a consistent state before the transaction begins, it should also be in a
consistent state after the transaction is completed.
01/22/2024
ACID Properties in DBMS
14

 The ACID properties are a set of characteristics that guarantee the reliability and consistency of
database transactions. These properties are fundamental to maintaining the integrity of data in a
database system.
 Isolation:
 Definition: Isolation ensures that the concurrent execution of transactions does not lead to interference
between them.
 Implication: Each transaction should appear as if it is the only transaction being executed, even though
multiple transactions may be occurring simultaneously. Isolation prevents one transaction from affecting the
outcome of another transaction that is running concurrently.
 Durability:
 Definition: Durability guarantees that once a transaction is committed, its effects persist even in the case of
system failures.
 Implication: Once a transaction is successfully completed (committed), the changes it made to the database are
permanent and survive any subsequent system failures, such as power outages or crashes. Durability is
typically achieved through mechanisms like transaction logging and periodic backups.
01/22/2024
Database Users
15

 A typical DBMS has users with different rights and


permissions who use it for different purposes.
 Some users retrieve data and some back it up.
 The users of a DBMS can be broadly categorized as follows −

01/22/2024
Database Users
16

 Administrators
 Administrators maintain the DBMS and are responsible for administrating the database. They are
responsible to look after its usage and by whom it should be used. They create access profiles for users
and apply limitations to maintain isolation and force security.
 Administrators also look after DBMS resources like system license, required tools, and other software
and hardware related maintenance.
 Designers
 Designers are the group of people who actually work on the designing part of the database.
 They keep a close watch on what data should be kept and in what format. They identify and design the
whole set of entities, relations, constraints, and views.
 End Users
 End users are those who actually reap the benefits of having a DBMS.
 End users can range from simple viewers who pay attention to the logs or market rates to sophisticated
users such as business analysts.
01/22/2024
DBMS Architecture
17

 The DBMS design depends upon its architecture. The basic


client/server architecture is used to deal with a large number of PCs,
web servers, database servers and other components that are
connected with networks.
 The client/server architecture consists of many PCs and a workstation
which are connected via the network.
 DBMS architecture depends upon how users are connected to the
database to get their request done.

01/22/2024
Types of DBMS Architecture
18

 Database architecture can be seen as a single tier or multi-tier.


 But logically, database architecture is of two types like: 2-tier
architecture and 3-tier architecture.

01/22/2024
1-Tier Architecture
19

• In this architecture, the database is directly available to the user. It


means the user can directly sit on the DBMS and uses it.
• Any changes done here will directly be done on the database itself. It
doesn't provide a handy tool for end users.
• The 1-Tier architecture is used for development of the local
application, where programmers can directly communicate with the
database for the quick response.

01/22/2024
2-Tier Architecture
20

 The 2-Tier architecture is same as basic client-server. In


the two-tier architecture, applications on the client end
can directly communicate with the database at the
server side. For this interaction, API's
like: ODBC, JDBC are used.
 The user interfaces and application programs are run on
the client-side.
 The server side is responsible to provide the
functionalities like: query processing and transaction
management.
 To communicate with the DBMS, client-side
application establishes a connection with the server
01/22/2024
side.
3-Tier Architecture
21

 The 3-Tier architecture contains another layer between


the client and server. In this architecture, client can't
directly communicate with the server.
 The application on the client-end interacts with an
application server which further communicates with the
database system.
 End user has no idea about the existence of the database
beyond the application server. The database also has no
idea about any other user beyond the application.
 The 3-Tier architecture is used in case of large web
application.
01/22/2024
3-tier Architecture
22

 It is the most widely used architecture to design a


DBMS.

01/22/2024
3-tier Architecture
23

 Database (Data) Tier − At this tier, the database resides along with its query processing
languages. We also have the relations that define the data and their constraints at this level.
 Application (Middle) Tier − At this tier reside the application server and the programs that
access the database. For a user, this application tier presents an abstracted view of the
database. End-users are unaware of any existence of the database beyond the application.
At the other end, the database tier is not aware of any other user beyond the application
tier. Hence, the application layer sits in the middle and acts as a mediator between the end-
user and the database.
 User (Presentation) Tier − End-users operate on this tier and they know nothing about any
existence of the database beyond this layer. At this layer, multiple views of the database
can be provided by the application. All views are generated by applications that reside in
the application tier.

01/22/2024
Database schema
27

 The data which is stored in the database at a particular moment of time is called an
instance of the database.
 The overall design of a database is called schema.
 A database schema is the skeleton structure of the database. It represents the logical
view of the entire database.
 A schema contains schema objects like table, foreign key, primary key, views, columns,
data types, stored procedure, etc.
 A database schema can be represented by using the visual diagram. That diagram shows
the database objects and relationship with each other.
 A database schema is designed by the database designers to help programmers whose
software will interact with the database. The process of database creation is called data
modeling.
01/22/2024
Cont…
28

 A schema diagram can display only


some aspects of a schema like the
name of record type, data type, and
constraints.
 Other aspects can't be specified
through the schema diagram.
 For example, the given figure neither
show the data type of each data item
nor the relationship among various
files.
01/22/2024
University Database Schema
29

01/22/2024
Bank Database Schema
30

01/22/2024
Database Languages in DBMS
31

 A DBMS has appropriate languages and interfaces to express


database queries and updates.
 Database languages can be used to read, store and update the data in
the database.

01/22/2024
Data Definition Language (DDL)
32

 DDL stands for Data Definition Language. It is used to define


database structure or pattern.
 It is used to create schema, tables, indexes, constraints, etc. in the
database.
 Using the DDL statements, you can create the skeleton of the
database.
 Data definition language is used to store the information of metadata
like the number of tables and schemas, their names, indexes, columns
in each table, constraints, etc.
01/22/2024
Data Definition Language (DDL)
33

 Here are some tasks that come under DDL:


 Create: It is used to create objects in the database.
 Alter: It is used to alter the structure of the database.

 Drop: It is used to delete objects from the database.

 Truncate: It is used to remove all records from a table.

 Rename: It is used to rename an object.

 Comment: It is used to comment on the data dictionary.

 These commands are used to update the database schema that's why
they come under Data definition language.
01/22/2024
Data Manipulation Language (DML)
34

 DML stands for Data Manipulation Language. It is used for accessing and
manipulating data in a database. It handles user requests.
 Here are some tasks that come under DML:
 Select: It is used to retrieve data from a database.
 Insert: It is used to insert data into a table.
 Update: It is used to update existing data within a table.
 Delete: It is used to delete all records from a table.
 Merge: It performs UPSERT operation, i.e., insert or update operations.
 Call: It is used to call a structured query language or a Java subprogram.
 Explain Plan: It has the parameter of explaining data.
 Lock Table: It controls concurrency.
01/22/2024
Data Control Language (DCL)
35

 DCL stands for Data Control Language. It is used to retrieve the stored or
saved data.
 The DCL execution is transactional. It also has rollback parameters.
 (But in Oracle database, the execution of data control language does not have
the feature of rolling back.)
 Here are some tasks that come under DCL:
 Grant: It is used to give user access privileges to a database.
 Revoke: It is used to take back permissions from the user.
 There are the following operations which have the authorization of Revoke:
 CONNECT, INSERT, USAGE, EXECUTE, DELETE, UPDATE and SELECT.
01/22/2024
Transaction Control Language (TCL)
36

 TCL is used to run the changes made by the DML statement. TCL can
be grouped into a logical transaction.
 Here are some tasks that come under TCL:
 Commit: It is used to save the transaction on the database.
 Rollback: It is used to restore the database to original since the last
Commit.

01/22/2024
Applications
37

 DBMS contains information about a particular enterprise


 Collection of interrelated data
 Set of programs to access the data
 An environment that is both convenient and efficient to use
 Database Applications:
 Banking: transactions
 Airlines: reservations, schedules
 Universities: registration, grades
 Sales: customers, products, purchases
 Online retailers: order tracking, customized recommendations
 Manufacturing: production, inventory, orders, supply chain
 Human resources: employee records, salaries, tax deductions
 Databases can be very large.
 Databases touch all aspects of our lives
01/22/2024
38 Thank you

01/22/2024

You might also like