introduction to database ait632 chapter 1 sungchul hong
TRANSCRIPT
Introduction to Database
AIT632
Chapter 1
Sungchul Hong
Database System
• The most important development in the field of software engineering.
• Database serve as the foundation for considerable progress in the basic science fields ranging from computing to biology.
Introduction
• Database– A collection of related data.
• DBMS (Database Management System)– The software that manages and controls access
to the database.
• Database application– A program that interacts with the database at
some point in its execution.
Examples of Databases
• Supermarket– Inventory
– Customer service
• Credit card• Booking a ticket at the travel agents• Using the local library• University• ??
Geographical Information System
Staff
staffNo fName lName position sex DOB salary branchNo
SL21 John White Manager M Oct/1/45 30000 B005
SG37 Ann Beech Assistant F Nov/10/60 12000 B003
SG14 David Ford Supervisor M Mar/24/58 18000 B003
SA9 Mary Howe Assistant F 19/Feb/70 9000 B007
SG5 Susan Brand Manager F Jun/3/40 24000 B003
SL41 Julie Lee Assistant F Jun/13/65 9000 B005
SELECT staffNo, fName, lName, position, salaryFROM StaffWHERE salary > 10000;
Table
Query Language
Relational Database Tables
ERD
ERD
File based system v.s. DBMS
• File based system
• Database system
Traditional File-Based Systems
• Each program defines and manages its own data.
• Separation and isolation of data
• Duplication of data
• Data dependence
• Incompatibility of files
• Fixed queries of application program
Database Approach
• A shared collection of logically related data, and a description of this data, designed to meet the information needs of an organization.
• System catalog (data dictionary)
• Program-data independence.
File-Based System
Sales Files
Data entry & report
File handling routines
File definition
The Database Management System (DBMS)
• A software system that enables users to define, create, maintain, and control access to the database.
• Data Definition Language(DDL)• Data Manipulation Language (DML)
– Structured Query Language (SQL)
• Views– Level of security, customization, provide consistent
structure
Components of the DBMS Environment
• Hardware – Client-server architecture– Backend, front end
• Software– DBMS, application programs, SQL
• Data– Operational data, meta data
• Procedure– Instructions and rules
• People
Roles in the Database Environment
• Data Administrator (DA)– Responsible for the management of the data resource
including database planning, development and maintenance of standards, policies, and procedures, and conceptual/logical database design.
• Database Administrator (DBA)-more technical– Responsible for the physical realization of the database,
including physical database design and implementation, security and integrity of the application users.
Roles in the Database Environment (2)
• Database Designer– Logical database designer
• Identifying the data, relationship between the data, and the constraints on the data.
• Business rules.
– Physical database designer• Mapping the logical database design into a set of tables and
integrity constraints.
• Selecting specific storage structures
• Designing security measures required on the data
Roles in the Database Environment (3)
• Application Developer– Provide the required functionality for the end-
users.
• End-Users– Naïve users– Sophisticated users.
Data Redundancy
Typical DBMS Functionality
• Define a database : in terms of data types, structures and constraints
• Construct or Load the Database on a secondary storage medium
• Manipulating the database : querying, generating reports, insertions, deletions and modifications to its content
• Concurrent Processing and Sharing by a set of users and programs – yet, keeping all data valid and consistent
Typical DBMS Functionality
Other features:– Protection or Security measures to
prevent unauthorized access– “Active” processing to take internal
actions on data– Presentation and Visualization of data
Advantages of DBMS
• Class
Advantages of DBMS (1/2)
• Control of data redundancy• Data consistency• More information from the same amount of data• Sharing of data• Improved data integrity• Improved security• Enforcement of standards
Advantages of DBMS (2/2)
• Economy of scale• Balance of confliction requirements• Improved data accessibility and responsiveness• Increased productivity• Improved maintenance through data independence• Increased concurrency• Improved backup and recovery services
Extending Database Capabilities
• New functionality is being added to DBMSs in the following areas:– Scientific Applications– Image Storage and Management– Audio and Video data management– Data Mining– Spatial data management– Time Series and Historical Data Management
The above gives rise to new research and development in incorporating new data types, complex data structures, new operations and storage and indexing schemes in database systems.
Database Disadvantage
• Class
Disadvantages of DBMS
• Complexity
• Size
• Cost of DBMS
• Additional hardware costs
• Cost of conversion
• Performance
• Higher impact of a failure
When not to use a DBMS
• Main inhibitors (costs) of using a DBMS:– High initial investment and possible need for additional
hardware.– Overhead for providing generality, security,
concurrency control, recovery, and integrity functions.
• When a DBMS may be unnecessary:– If the database and applications are simple, well
defined, and not expected to change.– If there are stringent real-time requirements that may
not be met because of DBMS overhead.– If access to data by multiple users is not required.
History of DBMS
• Apollo moon-landing project (1960s)– GUAM (Generalized Update Access Method)– Hierarchical structure
• IMS (Information Management System) (mid 1960s)– Serial storage – device (Tape recorder)
• IDS (Integrated Data Store) (mid 1960s)– Network DBMS
• CODASYL (Conference on Data Systems Languages)
History of DBMS
• DBTG (Data Base Task Group) – 1967• Relational Model – E. F. Codd, 1970
– R– SQL– DB2, SQL/DS, Oracle
• INGRES II, Informix, Access, FoxPro, Paradox, Interbase, and R:Base
• ER model – Chen, 1979– Semantic data modeling
• Object-Oriented DBMS, Object-Relational DBMS