DATABASE MANAGEMENT SYSTEMS. UNIT I Introduction to Database Systems

Similar documents
Chapter 1. Types of Databases and Database Applications. Basic Definitions. Introduction to Databases

Database Management Systems MIT Introduction By S. Sabraz Nawaz

Overview of Data Management

Introduction to Database Systems

Introduction to Databases

Overview of Data Management

Chapter 1. Introduction of Database (from ElMasri&Navathe and my editing)

Database Management System. Fundamental Database Concepts

Copyright 2007 Ramez Elmasri and Shamkant B. Navathe. Slide 1-1

Introduction: Databases and. Database Users

UNIT I. Introduction

What is Data? ANSI definition: Volatile vs. persistent data. Data. Our concern is primarily with persistent data

What is Data? Volatile vs. persistent data Our concern is primarily with persistent data

Chapter 1: Introduction

Introduction: Databases and Database Users. Copyright 2007 Ramez Elmasri and Shamkant B. Navathe Slide 1

Database Technology Introduction. Heiko Paulheim

Introduction Database Concepts

Introduction: Database Concepts Slides by: Ms. Shree Jaswal

Chapter 1 Introduction

B.H.GARDI COLLEGE OF MASTER OF COMPUTER APPLICATION. Ch. 1 :- Introduction Database Management System - 1

CS425 Fall 2016 Boris Glavic Chapter 1: Introduction

DATABASE CONCEPTS. Dr. Awad Khalil Computer Science & Engineering Department AUC

Chapter 1: Introduction

Databases and Database Management Systems

MIT Database Management Systems Lesson 01: Introduction

Chapter 1: Introduction. Chapter 1: Introduction

Chapter 1: Introduction

Database Management Systems MIT Lesson 01 - Introduction By S. Sabraz Nawaz

4/28/2014. File-based Systems. Arose because: Result

Copyright 2004 Pearson Education, Inc.

Chapter 1: Introduction

Database Management System

Introduction. Example Databases

SE352b: Roadmap. SE352b Software Engineering Design Tools. W5: Database Technology. Database Technology

Database Management Systems. Chapter 1

Database System Concepts and Architecture

Introduction to Database Concepts. Department of Computer Science Northern Illinois University January 2018

Chapter 1 Chapter-1

CS275 Intro to Databases. File Systems vs. DBMS. Why is a DBMS so important? 4/6/2012. How does a DBMS work? -Chap. 1-2

Copyright 2016 Ramez Elmasri and Shamkant B. Navathe

Basant Group of Institution

Mahathma Gandhi University

Meaning & Concepts of Databases

Database Management Systems (CPTR 312)

Course Logistics & Chapter 1 Introduction

Copyright 2007 Ramez Elmasri and Shamkant B. Navathe Slide 2-1

CS 338 Databases and Database Users INTRODUCTION

5/23/2014. Limitations of File-based Approach. Limitations of File-based Approach CS235/CS334 DATABASE TECHNOLOGY CA 40%

CS143: Relational Model

Data Modeling using ER Model

Database System Concepts and Architecture. Copyright 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley

CSE 3241: Database Systems I Databases Introduction (Ch. 1-2) Jeremy Morris

Database System Concepts and Architecture

Quick Facts about the course. CS 2550 / Spring 2006 Principles of Database Systems. Administrative. What is a Database Management System?

The Relational Model. Why Study the Relational Model? Relational Database: Definitions

Chapter 1: Introduction

Fundamentals of Information Systems, Seventh Edition

Outline. Database Management Systems (DBMS) Database Management and Organization. IT420: Database Management and Organization

Chapter 11 Database Concepts

DATABASTEKNIK - 1DL116

CSE 132A. Database Systems Principles

Database Systems: Learning Outcomes. Examples of Database Application. Introduction

Introduction. Who wants to study databases?

The Relational Model. Relational Data Model Relational Query Language (DDL + DML) Integrity Constraints (IC)

The Relational Data Model. Data Model

Review for Exam 1 CS474 (Norton)

DATABASE DESIGN I - 1DL300

Database Fundamentals Chapter 1

Introduction to Databases CS348

Chapter 1 Database System Concepts and Architecture. Nguyen Thi Ai Thao

1. Data Model, Categories, Schemas and Instances. Outline

John Edgar 2

Database Applications (15-415)

Lecture 01. Fall 2018 Borough of Manhattan Community College

The functions performed by a typical DBMS are the following:

LECTURE1: PRINCIPLES OF DATABASES

Why Study the Relational Model? The Relational Model. Relational Database: Definitions. The SQL Query Language. Relational Query Languages

Announcements. Using Electronics in Class. Review. Staff Instructor: Alvin Cheung Office hour on Wednesdays, 1-2pm. Class Overview

Relational Database Systems Part 01. Karine Reis Ferreira

Databases & Database Users

DB Basic Concepts. Rab Nawaz Jadoon DCS. Assistant Professor. Department of Computer Science. COMSATS IIT, Abbottabad Pakistan

Strategic Information Systems Systems Development Life Cycle. From Turban et al. (2004), Information Technology for Management.

CAS CS 460/660 Introduction to Database Systems. Fall

Introduction to Databases CSE 414. Lecture 2: Data Models

Administrivia. The Relational Model. Review. Review. Review. Some useful terms

Outline. Definitions History Basic concepts of DBMS Data Models Relational database Normalization

Upon completion of this Unit, the students will be introduced to the following

Data, Databases, and DBMSs

A Few Tips and Suggestions. Database System II Preliminaries. Applications (contd.) Applications

Data! CS 133: Databases. Goals for Today. So, what is a database? What is a database anyway? From the textbook:

Database Principle. Zhuo Wang Spring

Databases 1. Daniel POP

Database System Concepts

U1. Data Base Management System (DBMS) Unit -1. MCA 203, Data Base Management System

1/19/2012. Finish Chapter 1. Workers behind the Scene. CS 440: Database Management Systems

The Relational Model. Chapter 3. Comp 521 Files and Databases Fall

CISC 3140 (CIS 20.2) Design & Implementation of Software Application II

Data about data is database Select correct option: True False Partially True None of the Above

CSC 355 Database Systems

Chapter. Chapter Objectives

Transcription:

DATABASE MANAGEMENT SYSTEMS UNIT I Introduction to Database Systems

Terminology Data = known facts that can be recorded Database (DB) = logically coherent collection of related data with some inherent meaning Entities such as students, courses, sections Relationships between entities such as students taking courses and sections being part of courses Database management system (DBMS) = collection of programs that enable users to create and maintain a DB; general-purpose software system that facilitates process of defining, constructing, and manipulating DBs for various applications.

What is database? A shared collection of logically related data and a description of this data, designed to meet the information needs of an organization Data repository (data resource) Designed independently of applications (i.e., data abstraction) Long-term information needs at the enterprise level Primarily designed for quick and efficient data retrieval

What the Purpose for Learning about Database? Paradigm shift: Data driven business environment Production efficiencies Knowledge and innovation (e.g., knowledge management, business intelligence) Coordination of vendors (e.g., supply chain management Competitor and marketplace information Customer information (e.g., database marketing, CRM)

Early 60s History (1) Charles Bachman introduced first general purpose DBMS known as IDS (Turing Award 1973) at General Electric (GE) Integrated Data Store (IDS) formed the basis for N/w data model Network Data Model was standardized by the Conference on Data Systems Languages (CODASYL). Late 60s IBM developed IMS Information Management Systems (IMS) formed basis for Hierarchical Data Model Hierarchichal Data Model SABRE system for making airline reservation jointly by IBM and American Airlines (allowed several people to access the same data thro computer N/W) 70s Edgar Codd, at IBM proposed Relational Data Model (Turing Award 1981) Use of DBMSs for managing corporate data became standard practice

History (2) 80s Now Relational Data Model became dominant DBMS paradigm SQL query language for relational DBs developed as part of IBM s System R project is now the standard query language Transaction Management (concurrent execution of db programs) (James Gray, Turing Award 1999) Object-oriented Data Model Data warehouse and data mining Accessing databases through the web/internet Multimedia data Text data (information retrieval) Structure of the data (XML)

Traditional File-Based System Definition: "A collection of application programs that perform services for the end-users such as the production of reports. Each program defines and manages its own data." Customer transactions Operating expenses Inventory Vendors Payroll Program Program Program Program Program Report Report Report Report Report One file, one application

Data Redundancy Customer Order File Invoice number Customer account number Customer name, address, city, state, zip code Order date Product code, product description, price, unit Customer Account File Account Number Customer name, mailing address, city, state, zip code Customer Mailing List File Customer name, mailing address, city, state, zip code

File-Based Systems Records contain logically related data Limitations: Separation and isolation of data (one file, one program) Duplication of data Loss of data integrity - uncertainty of the correct version of data and no consistency Data dependence - application program defines the data Incompatibility of file formats Fixed queries/proliferation of application programs - little flexibility in meeting changing information needs

Database A shared collection of logically related data (and a description of this data), designed to meet the information needs of an organization. Data and Data Definitions Central Repository Separation Applications

Data Abstraction Separation between the data s structure (definition) and the application programs Application programs can be run on either the clients or server Data and Data Definitions Central Repository DBMS Applications

Organizing Data Entity - distinct object (i.e., person, place, thing, concept or event) Attribute - describes some aspect of the entity (object) Property of the entity Relationship - association between entities Entity Entity Attributes Customers Account_number Name Address Relationship Purchases Invoice_number Account_number Purchase_date

Database Customer Orders Order Items Products DBMS Management Queries Application Programs Manufacturers DDL DML Other Central Repository Controlled access Software (Organizational resource) Single Access Point Multitude of Applications

Advantages of the Database Approach Control of data redundancy Data consistency Efficient data access, Greater informational gain, more information from the same amount of data Sharing data, organizational resource (i.e., shared resource) Improved data integrity, validity and consistency Improved access and security Enforcement of standards Concurrency Access and Crash recovery Data Administration Reduced Application development time

Database Applications Traditional database applications (banks, library catalogs, inventory, airlines, universities) Multimedia databases (images) Geographic information systems Data warehouse and online analytical processing (OLAP) Real time and active database technology (sensor systems, safety-critical systems) World wide web (e-commerce, internet banking)

DBMS Available ORACLE DB2 by the IBM MS-SQL Teradata Sybase Informix

Data Model Collection of high level data description constructs that hide many low-level storage details Semantic data model More abstract, high level data model (makes it easier to describe about the data) Widely used one is ER model pictorially denotes entities and relationships among them Relational Model Relation set of records Schema A description of data in terms of a data model is schema Schema for a relation specifies its name, name of each field (or attribute or column) and type of each field. Example Students(sid: string, name: string, login: string, gpa: real) Each row in the relation is a record that describes the student

Other Data Models Relational Data model ( dominant model) Hierarchical data model Network model Object oriented model Object relational model

Types of Database Models HIERARCHICAL COLUMN RELATIONAL ROW VALUE TABLE

Database Architecture/ Levels of Data Abstractions External level (individual user views) Conceptual level (community user view) Internal level (storage view) Database

Conceptual Schema Describes data in terms of the data model of the DBMS. In a RDBMs, the conceptual schema describes all relations that are stored in the database. Eg. University Db Students (sid: string, name: string, gpa: real) Faculty (fid: string, fname: string, sal: real) Physical schema Specifies additional storage details Summarizes how the relations described in conceptual schema are actually stored on secondary storage devices like disks and tapes Decide on what file organizations to use to store relations and indexes to speed up data retrieval operations External Schema Allow data access to be customized at the level of individual users or groups of users.

An Example of the Three Levels SNo FName LName Age Salary Conceptual View SNo FName LName Age Salary External View1 SNo LName BranchNo External View2 BranchNo struct STAFF { int staffno; int branchno; char fname[15]; char lname[15]; struct date dateofbirth; float salary; struct STAFF *next; /* pointer to next Staff record */ }; index staffno; index branchno; /* define indexes for staff */ Internal View

Database Design Phases DATA ANALYSIS Entities - Attributes - Relationships - Integrity Rules LOGICAL DESIGN Tables - Columns - Primary Keys - Foreign Keys PHYSICAL DESIGN DDL for Tablespaces, Tables, Indexes

Data Independence Ability to change one schema level without affecting the higher level schemas Physical Data Independence Ability to change physical schema or internal schema without affecting conceptual or logical schema Logical Data Independence Ability to change logical schema without affecting External or view schema. (application programs) One imp. Adv of DBMS is data independence

Characteristics of the DB approach (1) Single repository of data defined once, maintained and accessed by users Self-describing nature of DB DB + description of DB structures and constraints stored in primary DB metadata (stored in catalog) DBMS software works with any number of DB applications Insulation between programs and data, and data abstraction Program--data independence Program--operation independence (OO DBMS) Abstraction: conceptual representation of data, no details of how data is stored or operators are implemented

Characteristics of the DB approach (2) Data model Relational data model Object-oriented data model Entity-relationship data model Support multiple views of data view = subset of DB virtual data derived from DB (not explicitly stored) Sharing data and multi-user transaction processing Concurrency control Online transaction processing (OLTP)

Query Languages Query questions involving data stored in dbms Relational Algebra formal query language based on collection of operators for manipulating relations Relational Calculus formal query language based on mathematical logic DDL: Data Definition Language Defines db structure Commands used are for creating, altering, query data DML: Data Manipulation Language For manipulating (inserting, deleting, updating) db contents Procedural and Non procedural (Declarative) DML

Types of DML Procedural DML Must be embedded in a programming language. Searches for and retrieves individual db records and uses looping and other constructs of the host programming language to retrieve multiple records Non-Procedural or Declarative DML Can be used as a stand-alone query language or can be embedded in a programming language. Searches for and retrieves information from multiple related db records in a single command

Components of a Database Environment Hardware Software: DBMS, application program and query software Data: Organized in a schema, partitioned into subschemas Procedures: Govern the design, access and use of the database People: Administrators (DA, DBA), designers (logical and physical), application developers and users (novice and high-powered)

Database System Users DATABASE SYSTEM DBMS Software Application Programs/Queries Software to process queries/programs Software to access stored data Stored Data Defn. (META-DATA). Stored Database

Users of the Database Day-to-day use of the DB Database administrators (DBA) Database designers End-users Casual end-users Naïve or parametric users Sophisticated end-users Stand-alone users System analysts and application programmers (software engineering)

Implications of the DB approach Potential for enforcing standard Reduce application development time Flexibility Availability of up-to-date info

When not to use a DBMS Unnecessary overhead costs Security, concurrency control, recovery and integrity High initial investment in hardware, software, training DB and applications are simple, well defined, not expected to change Real-time requirements not met (due to overhead) Multi-user access not required