versatilealligator
20 views
15 slides
Aug 05, 2024
Slide 1 of 15
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
About This Presentation
About Database Systems
Size: 36.02 KB
Language: en
Added: Aug 05, 2024
Slides: 15 pages
Slide Content
1
Introduction to
Database Systems
Motivation
Werner Nutt
2
Databases Are Everywhere
• Database= a large (?) collection of related data
• Classically, a DB modelsa real-world organisation
(e.g., enterprise,university)
–Entities(e.g., students, courses)
– Relationships(e.g., “Martin is taking IDS in 2010/11”)
• Changes in the organisation = changes in the database
• Examples:
– personnel records
– banking
– airline reservations
3
Scientific Databases (Examples)
•Biology:
e.g., DNA sequencesof genes, amino-acid sequences
of proteins, genesexpressed in tissues
(up to several Gigabytes)
• Astronomy:
e.g., locationand spectraof astronomic objects
(up to several Terabytes)
• Physics:
e.g., sensor measurementsin particle physics
experiments
(up to several Petabytes)
4
DB Tendencies
•Sensorsrecord data
ÎDBsgrow in size
ÎDBsbecome more widespread
Îdate may be less reliable, i.e., uncertain
• Multimediadata
ÎRequirements for larger storage
ÎNew query operations
(e.g., find a song by humming the melody,
find pictures with a given face)
• Data on the Web
ÎAccessed/changed by many people (Facebook,…)
ÎSpeed up access, loosen consistency (NoSQL)
5
Operations with Databases
•Design
–Definestructure and types of data
•Construction
–Createdata structures of DB, populateDB with data
•Manipulation of Data
–Insert, delete, update
–Query: “Which department pays the highest salary?”
– Create reports:
“List monthly salaries of employees, organised
by department, with average salary and total
sum of salaries for each dept”
6
An Ideal DB Implementation
Should Support:
• Structure
– data types
– data behaviour
• Persistence
– store data on
secondary storage
• Retrieval
– a declarative query
language
– a procedural database
programming language
• Performance
– retrieve and store data
quickly
• Data Integrity
• Sharing
– concurrency
• Reliability and resilience
• Large data volumes
7
Database Management System(DBMS) • A DBMS is a software package designed
to storeand managedatabases
• A DBMS provides generic functionality(see
previous slide) that otherwise would have to be
implemented over and over again
ÎReduced application development time
• Several brands, e.g.,
–Oracle Xi/Yg(Oracle), DB2 (IBM), SQL Server, Access
(Microsoft), MySQL, PostgreSQL, HSQLDB, SQLite
(open source)
8
Database Actors
Tool Developers
Operators and Maintenance
Personnel
End Users
•sophisticated
•casual
•‘parametric’ or
‘canned’ transactions
Database
Designers
Database
Administrator
(DBA)
Application
Programmers
DBMS developers
“on the scenes”
“behind the scenes”
Database
Database Management System
9
File System: A Physical Interface
Student
Admin
Scheduler
Payroll
Timetable
Year
Lists Money
Transfer
Student
Data
Lecturer
Data
Course
Data
10
Sharing Data: Replication
Î
Redundancy
Student Data
Course Data
Lecturer Data
Student
Admin
Payroll
Teaching Schedule
Lab
Timetable
Tutorials
Scheduler
11
Sharing Data and Operations
Course
Data
Lecturer Data
Student Admin
Scheduler
Payroll
ScheduleLab Timetable Tutorials
Student Data
Teaching
12
DBMS: A Logical Interface
University
Database
Metadata
student
course
lecturer
Lab
Timetable
Teaching
Schedule
Tutorials
Database
Management
System
University Database
Data
Data Dictionary
or
System Catalog
?
QUERIES
13
File System Approach
• Uncontrolled redundancy
• Inconsistent data
• Inflexibility
• Limited data sharing
• Poor enforcement of standards
• Low programmer productivity
• Excessive program maintenance
• Excessive data maintenance
14
DBMS Approach
• Controlled redundancy
– consistency of data &
integrity constraints
• Integration of data
– self-contained
– represents semantics
of application
• Data and operation
sharing
– multiple interfaces
• Services & controls
– security & privacy
controls
– backup & recovery
– enforcement of
standards
•Flexibility
– data independence
– data accessibility
– reduced program
maintenance
• Ease of application
development
15
However.... If an application is
•simple
• stringent real-time
• single user
• static,
files are the option of choice
DBMS downside:
• more expensive
• more complex
• general
• In a file system, data is
physically accessedand
not integrated
• In a DBMS, data is
logically accessedand
integrated:
– query language
– data dictionary
Summary: