lecture1: principles of databases prepared by l. nouf almujally 1 ref. chapter1
TRANSCRIPT
![Page 1: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/1.jpg)
Lecture1: Principles of Databases
Prepared by L. Nouf Almujally
1
Ref. Chapter1
![Page 2: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/2.jpg)
Chapter1 - Objectives
• Meaning of the term database.• Meaning of the term Database Management System
(DBMS).• Major components of the DBMS environment.• Users involved in the DBMS environment.• Advantages and disadvantages of DBMSs.
Lect
ure
1
2
![Page 3: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/3.jpg)
Data• Data: Known facts that can be recorded and have an
implicit meaning. ex)What does 3421 means?• facts about entities • Person's name, Phone, address, email, picture, …• Student's ID, name, subjects taken, results,…• Product's name, description, manufacturer, price,…• Book's publisher, author, title,…
• facts about relationships• BADER lives in Riyadh• Nora bought a book from university books shop on
01/03/11• Notice the different types of data
• numbers, strings, text, date, time, timestamp, • Text, picture, audio, video, graphics …
Lect
ure
1
3
![Page 4: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/4.jpg)
Data versus InformationData itself has no meaning without meta data which describes
data For example :
1012674, 28761, 153Does not give us any information, but knowing the meta data
that explains data : Staff_ID, Phone Number, room number
Information : is the data you process in a manner that makes it meaningful.
Lect
ure
1
4
Staff_ID Phone Number room number1012674 28761 153
![Page 5: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/5.jpg)
DatabaseDatabase
A collection of logically related data, including metadata - ”data about data”, that describes data
Data: name city birth Metadata: name - string, length<10 Khaled Dammam 01/01/70 city – string, length<15 Sara Abha 01/03/01 birth – date, format DD/MM/YY
Data is what you store in databaseInformation is what you retrieve from database
Two examplesall data required for the management of student records in a university.all data required for the management of books and borrowers in a
library.
Lect
ure
1
5
![Page 6: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/6.jpg)
Types of Databases
Numeric and Textual DatabasesMultimedia DatabasesGeographic Information Systems (GIS)Data WarehousesReal-time and Active Databases Le
cture
1
6
![Page 7: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/7.jpg)
Example of a Database(with a Conceptual Data Model)Mini-world: Some part of the real world about
which data is stored in a database. Mini-world for the example: Part of a UNIVERSITY
environment.
Some mini-world entities:STUDENTsCOURSEsSECTIONs (of COURSEs)Grade ReportPrerequiests
Lect
ure
1
7
![Page 8: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/8.jpg)
Lect
ure
1
8
![Page 9: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/9.jpg)
Lect
ure
1
9
![Page 10: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/10.jpg)
Example of a Database(with a Conceptual Data Model)Some mini-world relationships:
SECTIONs are of specific COURSEsSTUDENTs take SECTIONsCOURSEs have prerequisite COURSEsINSTRUCTORs teach SECTIONsCOURSEs are offered by DEPARTMENTsSTUDENTs major in DEPARTMENTs
Lect
ure
1
10
![Page 11: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/11.jpg)
Lect
ure
1
11
![Page 12: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/12.jpg)
Database Management Systems
Database Management System (DBMS) A software system that enables users to
create, maintain, and query the databaseMost DBMSs now have facilities that make
data access fast, reliable, secure and easy
Example DBMSsOracle MS AccessMySQL
Lect
ure
1
12
![Page 13: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/13.jpg)
Functions of a DBMS
• Data Storage, Retrieval, and Update.• Storing data definition in the form of data dictionary• Transaction Support • Transaction: executing program or process that
includes one or more database accesses, such as reading or updating of DB record
• Concurrency Control Services.• Recovery Services.• Security protection against unauthorized access.• Maintain and develop the database system
Lect
ure
1
13
![Page 14: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/14.jpg)
Application programs
• Database Application : is a collection of data and the programs that allow the manipulation of these data to meet the information needs by an enterprise.• built on top of DBMS• to satisfy end users special requirements and
preference
Lect
ure
1
14
![Page 15: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/15.jpg)
Examples of Database Applications
• Purchases from the supermarket• PNU Student Registration • PNU Library• Saudi Airline Reservation• Purchases using your credit card • Booking a holiday at the travel agents• Using the Internet
Lect
ure
1
15
![Page 16: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/16.jpg)
Database SystemDatabase System: The DBMS software together with
the data itself. Sometimes, the applications are also included.
(DB + DBMS + Application program)
To manage large amounts of dataEfficientlyReliablySecurelyconveniently
Lect
ure
1
16
![Page 17: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/17.jpg)
Lect
ure
1
17
![Page 18: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/18.jpg)
Database Approach
Lect
ure
1
18
![Page 19: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/19.jpg)
Main Characteristics of the Database Approach
• Self-describing nature of a database system: A DBMS catalog stores the description of the database. The description is called meta-data). This allows the DBMS software to work with different databases.
• Insulation between programs and data: Called program-data independence. Allows changing data storage structures and operations without having to change the DBMS access programs (application program).
Lect
ure
1
19
![Page 20: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/20.jpg)
Main Characteristics of the Database Approach
• Data Abstraction: A data model is used to hide storage details and present the users with a conceptual view of the database.
• Support of multiple views of the data: Each user may see a different view of the database, which describes only the data of interest to that user.
Lect
ure
1
20
![Page 21: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/21.jpg)
Views
• Allows each user to have his or her own view of the database.• A view is essentially some subset of the
database. • Benefits:• Reduce complexity• Provide a level of security• Present a consistent, unchanging picture of the
structure of the database, even if the underlying database is changed 21
Pearson Education © 2009
![Page 22: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/22.jpg)
Main Characteristics of the Database Approach
Sharing of data and multiuser transaction processing : allowing a set of concurrent users to retrieve and to update the database. Concurrency control within the DBMS guarantees that each transaction is correctly executed or completely aborted.OLTP (Online Transaction Processing) is a major part of
database applications.
Lect
ure
1
22
![Page 23: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/23.jpg)
Advantages of Using the Database Approach
• Controlling redundancy in data storage and in
development and maintenance efforts.
• Sharing of data among multiple users.
• Restricting unauthorized access to data.
• Providing persistent storage for program Objects
• Providing Storage Structures for efficient Query
Processing
Lect
ure
1
28
![Page 24: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/24.jpg)
Advantages of Using the Database Approach
• Providing backup and recovery services.• Providing multiple interfaces to different
classes of users.• Representing complex relationships among
data.• Enforcing integrity constraints on the
database.
Lect
ure
1
29
![Page 25: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/25.jpg)
Disadvantages of Database Approach
• Complexity• Cost of DBMS• Additional hardware costs• Performance• Higher impact of a failure Le
cture
1
25
![Page 26: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/26.jpg)
Components of DBMS Environment
• Hardware• Can range from a PC to a network of computers.
• Software• DBMS, operating system, network software (if
necessary) and also the application programs.• Data• Procedures• Instructions and rules that should be applied to the
design and use of the database and DBMS.• People
Lect
ure
1
26
![Page 27: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/27.jpg)
Components of DBMS Environment
27
![Page 28: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/28.jpg)
Lect
ure
1
28
DBMSApp
Program
DB
UserRequirement
Procedure
DBA
Naïve End User
Applicationprogrammer
DB DesignerSystem Analyst
Sophisticated End User
H/W
Design
Communicate
Manage
Write Write
Program
Use
Use
Database Users
![Page 29: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/29.jpg)
Database Users
• System Analyst: Determine the user requirements and develop the system specifications.
• Database Designers:• responsible for defining the content, the structure,
the constraints, and functions or transactions against the database.
• Application Programmer• Implement programs meet the end user needs• Test , debug , document, and maintain transactions
Lect
ure
1
25
![Page 30: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/30.jpg)
Database Users
• Database administrators: responsible for:• authorizing access to the database• coordinating and monitoring the DB use• acquiring software, and hardware resources• monitoring efficiency of operations. Le
cture
1
25
![Page 31: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/31.jpg)
Database Users• End-users: they use the data for queries, reports and
some of them actually update the database content.• Categories of End-users:
Naïve : (Queries / modifies data)- they make up a large section of the end-user
population.- They use previously well-defined functions in the
form of “canned transactions” against the database.
- Examples: bank-tellers or reservation clerks.Sophisticated : Forms requests in a database query
language.
Lect
ure
1
25
![Page 32: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/32.jpg)
Lect
ure
1
32
![Page 33: Lecture1: Principles of Databases Prepared by L. Nouf Almujally 1 Ref. Chapter1](https://reader030.vdocument.in/reader030/viewer/2022032600/56649dac5503460f94a9b021/html5/thumbnails/33.jpg)
References
• “Database Systems: A Practical Approach to Design, Implementation and Management.”Thomas Connolly, Carolyn Begg.5th Edition, Addison-Wesley, 2009.
• Fundamentals of Database Systems", Ramez Elmasri, Shamkant B. Navathe, Addison Wesley, The Latest Edition.
Lect
ure
1
33