Lec 1: Database Systems Dr. Nader Mahmoud /21 Course Syllabus Introduction Database Environment Database Architectures and the Web The Relational Model Relational Algebra Database System Development Lifecycle Entity-Relationship Modeling Normalization Methodology Database Design RAID 2/21 Chapter 1: Introduction to Database Some common uses of database systems. Characteristics of file-based systems. Problems with file-based approach. Meaning of the term Database an Database Management System (DBMS). Major components of the DBMS environment. Personnel involved in the DBMS environment. Advantages and disadvantages of DBMSs. 3/21 1) Some common uses of database systems: • Purchases from the supermarket • Booking a holiday at the travel agents • Using the local library • Taking out insurance • Using the Internet • Studying at university (Student affairs) 4/21 2) File-Based Systems • Collection of application programs that perform services for the end users (e.g. reports). • Each program defines and manages its own data (Data De-centralization). 5/21 2) File-Based Systems 6/21 3) Limitations of File-Based Approach 1. Separation and isolation of data • Each program maintains its own set of data. • Users of one program may be unaware of potentially useful data held by other programs. 2. Duplication of data • Wasted space and time. • Leads to loss of integrity, data is no longer consistent 7/21 3) Limitations of File-Based Approach 3. Data dependence • File structure is defined in the program code. 4. Incompatible file formats • Programs are written in different languages, and so cannot easily access each other’s files. 5. Fixed Queries/Proliferation of application programs • Programs are written to satisfy particular functions. • Any new requirement needs a new program. 8/21 3) Database Approach • Arose because: 1. Definition of data was embedded in application programs, rather than being stored separately and independently. 2. No control over access and manipulation of data beyond that imposed by application programs. • Result: The database and Database Management System (DBMS). 9/21 4) Database • Shared collection of logically related data (and a description of this data), designed to meet the information needs of an organization. • Logically related data comprises entities, attributes, and relationships of an organization’s information. • System catalog (metadata) provides description of data to enable program–data independence. 10/21 4) Database Management System (DBMS) • A software system that enables users to define, create, maintain, and control access to the database (Microsoft Access, MySql, ORACLE, …. etc). • (Database) application program: a computer program that interacts with database by issuing an appropriate request (SQL statement) to the DBMS. 11/21 4) Database Management System (DBMS) 12/21 4) Database Management System (DBMS) • Data definition language (DDL). • Permits specification of data types, structures and any data constraints. • All specifications are stored in the database. • Data manipulation language (DML). • General enquiry facility (query language) of the data. 13/21 4) Database Management System (DBMS) • a security system • an integrity system • It provide controlled access to database : • a concurrency control system • a recovery control system • a user-accessible catalog 14/21 4) Database Management System (DBMS) Views • Allows each user to have his or her own view of the database. • A view is essentially some subset of the database. 15/21 4) Database Management System (DBMS) Views Benefits • Reduce complexity • Provide a level of security • Provide a mechanism to customize the appearance of the database • Present a consistent, unchanging picture of the structure of the database, even if the underlying database is changed 16/21 5) Components of DBMS Environment Hardware Software Can range from a PC to a network of computers. DBMS, operating system, network software (if necessary) and also the application programs. Data 17/21 Used by the organization (operational data and metadata) Procedures Instructions and rules that govern the design and use of the database and DBMS. 5) Components of DBMS Environment People Data Administrator (DA) Database Administrator (DBA) Database Designer (Logical & Physical) End Users (naïve and sophisticated) Application Programmers 18/21 6) Advantages of DBMSs • Control of data redundancy • Economy of scale • Data consistency & Improved data integrity • Increased productivity • More information from the same amount of data • Improved data accessibility (cross-referenced) • Sharing of data • Increased concurrency • Improved security • Backup and recovery services 19/21 6) Disadvantages of DBMSs • Complexity • Size • Cost of DBMS • Additional hardware costs • Cost of conversion • Performance • Higher impact of a failure 20/21 End of Chapter 1 21/21