Chapter One Overview of Database
description
Transcript of Chapter One Overview of Database
![Page 1: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/1.jpg)
Chapter OneOverview of Database
Objectives:-Introduction
-DBMS architecture-Definitions-Data models-DB lifecycle
![Page 2: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/2.jpg)
2
Definitions Database Management System
(DBMS): is a record keeping system (software) that allows one or more people to use or modify the data.
![Page 3: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/3.jpg)
3
Why DBMS: Centralized Control
Redundancy(Eliminated or Reduced)(Propagating update)
Inconsistency (Avoided) Shared Data Standardization Security Integrity Transaction Support
Complex Design Required Specialist (DBA) Training Cost Program Failures (potential) Cost
![Page 4: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/4.jpg)
4
Good DBMS must have: Support for at least one Data Model Support for certain high level languages for
Retrieve, Insert, Deletes, etc. into Database (Navigate)
Transaction Management:Capable of access to DB by many users at
once Access control:
Limit access to DB by unauthorized user Recovery capability form system failure Security System
![Page 5: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/5.jpg)
5
Architecture of DBMS
View Level: Def: Example (SQL)
CREATE VIEW GradStudentSELECT Name, ID, GPAFROM Students;
Data Manipulation Language (DML) (Query Language)
View Conceptual DB Physical DB
![Page 6: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/6.jpg)
6
Architecture of DBMS Conceptual Level:
Describe what data are stored & relationship among data (DB)
Example:
Students=RecordName:char[15];ID:Integer;
End;
![Page 7: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/7.jpg)
7
Architecture of DBMS
Example: Create table Students
(Name VARCHAR2(30), ID NUMBER(14), GPA NUMBER(3,2));
Data Definition Language (DDL)
![Page 8: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/8.jpg)
Application Program
SystemCalls
QueryDB
Scheme
DMLCompiler
QueryProcessor
DDLCompiler
Application Program
Object CodeDB Manager
File Manager
Data DictionaryData File
Conceptual Level
InternalLevel
ExternalLevel
EndUser
DB AdministratorApplication Program
![Page 9: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/9.jpg)
10
Definitions File DB DBMS
![Page 10: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/10.jpg)
11
Definitions (Continued)
Instances & Schemes
Instance: The collection of Information stored in a DB at a particular instant of time
Scheme: The overall design of the DB
Example:Students (ID, Name, Address, GPA)
111, John, 34 1st, 2.6, 123, Mary, 18 Main, 2.8
(Plan for view is called sub-scheme)
![Page 11: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/11.jpg)
12
Definitions (Continued)
Data Independence:a. Physical data Independence
The ability to modify physical scheme without changing the application program
b. Logical data Independence:The ability to modify conceptual scheme without changing the application program
![Page 12: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/12.jpg)
13
Definitions (Continued)
Data Definition Language (DDL)a. A set of instructions which define
the DB schemeb. Result of compilation of DDL in a set
of tables which are stored in a special file called “data dictionary”.
![Page 13: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/13.jpg)
14
Definitions (Continued)
Data Manipulation Language (DML) A set of instructions to manipulate data. (Insert, Retrieve, Delete, …)
a. Types of DMLi. Procedural:ii. Non Procedural (Declarative)
![Page 14: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/14.jpg)
15
Definitions (Continued)
Database Manager:A program which provides the
interface between data stored in DB and application programs
![Page 15: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/15.jpg)
16
Definitions (Continued)
Database manager is responsible for:
a. Interaction with the file manager (retrieving & updating data in DB)
b. Integrity enforcement:c. Data value must satisfy certain
types of consistency constraintsd. Security enforcemente. Backup & recovery
![Page 16: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/16.jpg)
17
Definitions (Continued)
Database Administrator (DBA):Person(s) who involves in central control
Function of DBA: 1. Scheme definitions2. Storage structure & access method (Physical
organization)3. Modification of scheme & physical
organization4. Granting of authorization for data access
![Page 17: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/17.jpg)
18
Definitions (Continued)
Database Usersa. Application Programmerb. End User (Query Language)
Host Language:High level programming language
supported by DBMS that can be used to manipulate DB
![Page 18: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/18.jpg)
19
Overall System Structure Database Administration
File Manager Data File Data Dictionary Database Manager
Query Processes DML Compiler DDL Compiler
![Page 19: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/19.jpg)
20
Data Models Introduction:
Physical Model Mathematical Model Abstract Model Data Model
![Page 20: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/20.jpg)
21
Data Model Describes Data, Data Relationships,
Data Semantics and Data Constraints
<Object Name, Object Property, Property Values, Time>
Example: Car PersonEmployer Manager
![Page 21: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/21.jpg)
22
Representing Models
• -Networking• -Categories
• Strictly Typed• Loosely Typed
![Page 22: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/22.jpg)
23
Types of Models
1. Object Based logical Model2. Record Based Model3. Physical Data Model4. Object Record Model
![Page 23: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/23.jpg)
24
Object Based Logical Models Describing data at the conceptual and
view levels Flexible structure Specify data constraints explicitly
Example:1. Entity-Relationship2. Semantic Data Modeling3. Binary Data Model4. Infological Model
![Page 24: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/24.jpg)
25
Entity-Relationship Model (ER Model):
Consists of a collection of basic objects called (Entities) and (Relationships)
An entity is an object which exists and is distinguished from other objects
Each entity has a set of attributes which describes the object
A relationship is an association among several entities
![Page 25: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/25.jpg)
26
Binary Data Model Base on graph data model; nodes and
arcs Node represents a classification of data
instances into a type called category (Generalization)
Arc represents a binary relationship between categories and is called binary relation
This graph is called Type Graph
![Page 26: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/26.jpg)
27
Record-Based Logical Models
Describing data at the conceptual and view levels
They do not provide facilities for specifying data constraints explicitly
![Page 27: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/27.jpg)
28
Record-Based Logical Models (Continued)
1. Relational data and relationships are represented by a collection of Tables(Relations)
2. Network data are represented by collections of records and relationships among data are represented by links
3. Hierarchical similar to network, but records are organized as a collection of trees rather than arbitrary graph
![Page 28: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/28.jpg)
29
Physical Data Models Describes data at the lowest level
![Page 29: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/29.jpg)
30
Object Relational Present information in object form Object of object type (hierarchical) Inheritance Encapsulation Interface Polymorphism
![Page 30: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/30.jpg)
31
Database LifecycleStage One:
a. Analysis: Study and Analyze business requirements Interview manager, and users for the
information requirements Incorporate the future system specifications
b. Develop a user system specifications
![Page 31: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/31.jpg)
32
Database Lifecycle
Stage Two:Design
Entity relational model Unify modeling language
Check the design
Stage Three:Build the Databases/Document/Test
Create tables, views and programs Produce manuals (User documentation)
![Page 32: Chapter One Overview of Database](https://reader034.fdocuments.in/reader034/viewer/2022051418/56814f09550346895dbc9b6f/html5/thumbnails/32.jpg)
33
Database Lifecycle
Stage Four:Product delivery
Load the software Monitor the performance