DBMS Basic Conecpts
DBMS Basic Conecpts
1
Learning Objectives
2-3
What is Data? (Cont.)
4
Problems in Storing and Accessing Data
• Additional issues include: data security, data privacy, and backup and
recovery.
5
Data Security
6
Data Privacy
7
Backup and Recovery
8
Data Accuracy
• When a new application is written, new data files are created to store
its data.
9
Data as a Corporate Resource
10
The Database Environment
• Fast hardware
11
The Database Environment
12
The Database Environment
13
Types of Databases and Database
Applications
• Traditional Applications:
• Numeric and Textual Databases
• More Recent Applications:
• Multimedia Databases
• Geographic Information Systems (GIS)
• Biological and Genome Databases
• Data Warehouses
• Mobile databases
• Real-time and Active Databases
14
Recent Developments (cont.)
15
Recent Developments (cont.)
16
Basic Definitions
• Database:
• A collection of related data.
• Data:
• Known facts that can be recorded and have an implicit meaning.
• Mini-world:
• Some part of the real world about which data is stored in a database.
For example, student grades and transcripts at a university.
• Database Management System (DBMS):
• A software package/ system to facilitate the creation and
maintenance of a computerized database.
• Database System:
• The DBMS software together with the data itself. Sometimes, the
applications are also included.
17
Impact of Databases and Database
Technology
• Businesses: Banking, Insurance, Retail, Transportation, Healthcare,
Manufacturing
• Service Industries: Financial, Real-estate, Legal, Electronic Commerce,
Small businesses
• Education : Resources for content and Delivery
• More recently: Social Networks, Environmental and Scientific
Applications, Medicine and Genetics
• Personalized Applications: based on smart mobile devices
18
Simplified database system environment
19
Typical DBMS Functionality
20
Database Model Requirements
• PQRI:
Persistency Quantity
Database model
Integrity
Reactivity
21
Application Activities Against a Database
22
Additional DBMS Functionality
23
Example of a Database
(with a Conceptual Data Model)
24
Example of a Database
(with a Conceptual Data Model) (cont.)
25
Example of a simple database
26
Main Characteristics of the Database
Approach
• Self-describing nature of a database system:
• A DBMS catalog stores the description of a particular database (e.g.
data structures, types, and constraints)
• The description is called meta-data*.
• This allows the DBMS software to work with different database
applications.
• Insulation between programs and data:
• Called program-data independence.
• Allows changing data structures and storage organization without
having to change the DBMS access programs.
-----------------------------------------------------------------------------
* Some newer systems such as a few NOSQL systems need no meta-
data: they store the data definition within its structure making it self
describing
27
Example of a simplified database catalog
28
Main Characteristics of the Database
Approach (cont.)
• Data Abstraction:
• A data model is used to hide storage details and present the users with a
conceptual view of the database.
• Programs refer to the data model constructs rather than data storage details
• 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.
29
Main Characteristics of the Database
Approach (cont.)
• Sharing of data and multi-user transaction processing:
• Allowing a set of concurrent users to retrieve from and to
update the database.
• Concurrency control within the DBMS guarantees that each
transaction is correctly executed or aborted
• Recovery subsystem ensures each completed transaction has
its effect permanently recorded in the database
• OLTP (Online Transaction Processing) is a major part of
database applications. This allows hundreds of concurrent
transactions to execute per second.
30
Database Users
31
Database Users – Actors on the Scene
32
Database End Users
33
Database End Users (cont.)
• Sophisticated:
• These include business analysts, scientists, engineers, others thoroughly familiar with the
system capabilities.
• Many use tools in the form of software packages that work closely with the stored database.
• Stand-alone:
• Mostly maintain personal databases using ready-to-use packaged applications.
• An example is the user of a tax program that creates its own internal database.
• Another example is a user that maintains a database of personal photos and videos.
34
Database Users – Actors on the Scene (cont.)
• System Analysts and Application Developers
This category currently accounts for a very large proportion of the IT
work force.
• System Analysts: They understand the user requirements of naïve and sophisticated
users and design applications including canned transactions to meet those requirements.
• Application Programmers: Implement the specifications developed by
analysts and test and debug them before deployment.
• Business Analysts: There is an increasing need for such people who can analyze vast
amounts of business data and real-time data (“Big Data”) for better decision making related to
planning, advertising, marketing etc.
35
Database Users – Actors behind the Scene
• System Designers and Implementors: Design and implement DBMS packages in
the form of modules and interfaces and test and debug them. The
DBMS must interface with applications, language compilers, operating
system components, etc.
• Tool Developers: Design and implement software systems called tools for
modeling and designing databases, performance monitoring,
prototyping, test data generation, user interface creation, simulation
etc. that facilitate building of applications and allow using database
effectively.
• Operators and Maintenance Personnel : They manage the actual running and
maintenance of the database system hardware and software
environment.
36
Advantages of Using the Database Approach
37
Advantages of Using the Database Approach
(cont.)
• Providing optimization of queries for efficient processing.
• Providing backup and recovery services.
• Providing multiple interfaces to different classes of users.
• Representing complex relationships among data.
• Enforcing integrity constraints on the database.
• Drawing inferences and actions from the stored data using deductive
and active rules and triggers.
38
Additional Implications of Using the Database Approach
39
Additional Implications of Using the Database Approach
(cont.)
40
Historical Development of Database
Technology
• Early Database Applications:
• The Hierarchical and Network Models were introduced in mid
1960s and dominated during the seventies.
• A bulk of the worldwide database processing still occurs using
these models, particularly, the hierarchical model using IBM’s
IMS system.
• Relational Model based Systems:
• Relational model was originally introduced in 1970, was heavily
researched and experimented within IBM Research and several
universities.
• Relational DBMS Products emerged in the early 1980s.
41
Historical Development of Database Technology (cont.)
42
Historical Development of Database Technology (cont.)
43
Extending Database Capabilities
44
Extending Database Capabilities (cont.)
45
Extending Database Capabilities (cont.)
47
When not to use a DBMS
48
DBMS Languages
49
DBMS Languages (cont.)
50
DBMS Languages (cont.)
51
Types of DML
52
DBMS Interfaces
53
DBMS Programming Language Interfaces
54
User-Friendly DBMS Interfaces
• Menu-based (Web-based), popular for browsing on the web
• Forms-based, designed for naïve users used to filling in entries on a form
• Graphics-based
• Point and Click, Drag and Drop, etc.
• Specifying a query on a schema diagram
• Natural language: requests in written English
• Combinations of the above:
• For example, both menus and forms used extensively in Web database interfaces
55
Other DBMS Interfaces
56