Professional Documents
Culture Documents
CSE 480: Database Systems: Lecture 1: Introduction
CSE 480: Database Systems: Lecture 1: Introduction
Lecture 1: Introduction
Reference:
1
Database Systems are Pervasive
Retail
Banking
Law enforcement
2
Database-Driven Web Sites
3
What is a Database?
4
Example of a Database
Entities:
– STUDENTs
– COURSEs
– SECTIONs
– DEPARTMENTs
– INSTRUCTORs
5
Example of a Database
6
Example of a Database
Database Architect
or Designer
7
Database Management System (DBMS)
Examples of DBMS
– MS Access, MS SQL Server, IBM DB2, Oracle, Sybase,
Postgres, mySQL, and many more
8
File Server Architecture (no DBMS)
Thick client
Source:
Modern Database
Management. 6th Edition,
Jeffrey A. Hoffer, Mary B.
Prescott, Fred R.
McFadden
9
Client-Server DBMS Architecture
Thin client
Source:
Modern Database
DBMS running on database Management. 6th Edition,
server; performs all data Jeffrey A. Hoffer, Mary B.
Prescott, Fred R.
storage and access operations McFadden
10
Three-tier Architecture
Source:
Modern Database
Management. 6th Edition,
Jeffrey A. Hoffer, Mary B.
Prescott, Fred R.
McFadden
11
Typical DBMS Functionalities
Define a database
– Specify the structure of the data records
Construct a database
– Store the data on some storage medium controlled by the DBMS
12
Characteristics of DBMS
Self-Describing
Provides insulation between programs and data
Allows multiple views
Allows multi-user transaction processing
13
Characteristics of DBMS
– This allows the DBMS software to work with any types of data
(banking, university, company, etc)
14
Example of DBMS Catalog
Information in DBMS
catalog are needed
for query processing
and optimization (to
be discussed more
in lectures 22-24)
15
Characteristics of DBMS
– Program-operation independence
In OO and OR database systems, users can define operations
(methods) on data using an interface; implementation of the
operation (method) can be separately specified
16
Characteristics of DBMS
– Example:
Student database may contain information about student’s name,
SSN, courses taken and grades, salary, etc
Users of the database include registrar office and payroll department
– Registrar doesn’t need to know what is student’s salary
– Payroll doesn’t need to know what is student’s GPA
17
Characteristics of DBMS
18
Database System Concepts
Data Models
Database Schema vs Database Instances
DBMS Languages
19
Abstraction
20
Data Model
User/Program
Physical data
111000010010111
storage
011010111011011
21
Examples of Data Models
Network Model
Hierarchical Model
Relational Model (most widely used)
Object-Oriented Data Models
Object-Relational Models
22
Relational Data Model
23
Database Schemas versus Instances
Database Schema:
– The description of a database
Includes descriptions of data elements, data types, and constraints
– Schema Diagram: An illustrative display of a database schema
24
Example of a Database Schema
25
Example of a Database State
26
Database Schema vs. Database State
Distinction
– The database schema changes very infrequently.
– The database state changes every time the database is
updated.
27
Three-Schema Architecture
External
schemas
Internal Schema
28
Internal Schema/Level
29
Conceptual Schema/Level
30
External Schema/Level
External
schemas
31
External Schema
32
DBMS Languages
33
DBMS Languages
SELECT MgrSSN
FROM DEPARTMENT
WHERE DName = ‘Payroll’;
34
Example of SQL Embedded in Java
35
Database System Environment
36
MySQL Account
37