ITN 170 - MySQL Database Programming 1 Lecture 3 :Database Analysis and Design (I) ITN 170 MySQL Database Programming.

Slides:



Advertisements
Similar presentations
Relational Database. Relational database: a set of relations Relation: made up of 2 parts: − Schema : specifies the name of relations, plus name and type.
Advertisements

SQL Lecture 10 Inst: Haya Sammaneh. Example Instance of Students Relation  Cardinality = 3, degree = 5, all rows distinct.
Accounting System Design
Module 2 Designing a Logical Database Model. Module Overview Guidelines for Building a Logical Database Model Planning for OLTP Activity Evaluating Logical.
Systems Development Life Cycle
10/25/2001Database Management -- R. Larson Data Administration and Database Administration University of California, Berkeley School of Information Management.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 7 Data Modeling Using the Entity- Relationship (ER) Model.
Fundamentals, Design, and Implementation, 9/e Chapter 11 Managing Databases with SQL Server 2000.
Entity-Relationship Model and Diagrams (continued)
1 Pertemuan 09 Database Matakuliah: D0524 / Algoritma dan Pemrograman Komputer Tahun: 2005 Versi:
History of the Database. 2 home back first prev next last What Will I Learn? In this lesson, you will learn to: –Describe the evolution of the database.
SQL Overview Defining a Schema CPSC 315 – Programming Studio Spring 2008 Project 1, Lecture 3 Slides adapted from those used by Jeffrey Ullman, via Jennifer.
July 14, 2015ICS 424: recap1 Relational Database Design: Recap of ICS 324.
Structured Query Language SQL: An Introduction. SQL (Pronounced S.Q.L) The standard user and application program interface to a relational database is.
Seminar #1 – Refreshing databases concepts and SQL CM036: Advanced Databases1 Seminar 1: Revisiting Databases and SQL Purpose To refresh basic concepts.
Transforming Data Models into Database Designs
APPENDIX C DESIGNING DATABASES
Database Systems Lecture 5 Natasha Alechina
10/5/1999Database Management -- R. Larson Data Administration and Database Administration University of California, Berkeley School of Information Management.
Introduction To Databases IDIA 618 Fall 2014 Bridget M. Blodgett.
1 Database Requirements and Design. 2 DATA PEOPLE PROCEDURES HARDWARE SOFTWARE The Product: a working system.
Computer System Analysis Chapter 10 Structuring System Requirements: Conceptual Data Modeling Dr. Sana’a Wafa Al-Sayegh 1 st quadmaster University of Palestine.
CSE314 Database Systems Data Modeling Using the Entity- Relationship (ER) Model Doç. Dr. Mehmet Göktürk src: Elmasri & Navanthe 6E Pearson Ed Slide Set.
Information storage: Introduction of database 10/7/2004 Xiangming Mu.
1 C omputer information systems Design Instructor: Mr. Ahmed Al Astal IGGC1202 College Requirement University Of Palestine.
Chapter 4 The Relational Model.
1 Introduction to databases concepts CCIS – IS department Level 4.
Managing the development and purchase of information systems (Part 1)
Business Process Modeling
DATA MODELING AND DATABASE DESIGN
o At the end of this lesson, you will be able to:  Describe the life-cycle development phases  Discuss the theoretical and physical aspects of a relational.
ITEC224 Database Programming
Copyright  Oracle Corporation, All rights reserved. I Introduction.
RDB/1 An introduction to RDBMS Objectives –To learn about the history and future direction of the SQL standard –To get an overall appreciation of a modern.
Introduction to SQL Steve Perry
CST203-2 Database Management Systems Lecture 2. One Tier Architecture Eg: In this scenario, a workgroup database is stored in a shared location on a single.
1 Introduction to Database Systems. 2 Database and Database System / A database is a shared collection of logically related data designed to meet the.
Chapter 9 Designing Databases Modern Systems Analysis and Design Sixth Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich.
1 Relational Database Development Alison Taylder Consultant ITC-ILO, Turin 25 th November 2004.
FEN  Concepts and terminology  Operations (relational algebra)  Integrity constraints The relational model.
Oracle9i Performance Tuning Chapter 1 Performance Tuning Overview.
Lecture 12 Designing Databases 12.1 COSC4406: Software Engineering.
Normalization (Codd, 1972) Practical Information For Real World Database Design.
Lecture2: Database Environment Prepared by L. Nouf Almujally & Aisha AlArfaj 1 Ref. Chapter2 College of Computer and Information Sciences - Information.
CS370 Spring 2007 CS 370 Database Systems Lecture 4 Introduction to Database Design.
Lecture2: Database Environment Prepared by L. Nouf Almujally 1 Ref. Chapter2 Lecture2.
FEN Introduction to the database field:  The Relational Model Seminar: Introduction to relational databases.
Overview of Database Development Data Modeling and Relational Database Design.
Session 2: SQL (A): Parts 1 and 2 Original materials supplied by the Oracle Academic Initiative (OAI). Edited for classroom use by Professor Laku Chidambaram.
SQL: Part 1 Original materials supplied by the Oracle Academic Initiative (OAI). Edited for classroom use by Professor Laku Chidambaram. Not for commercial.
IS2803 Developing Multimedia Applications for Business (Part 2) Lecture 1: Introduction to IS2803 Rob Gleasure
ASET 1 Amity School of Engineering & Technology B. Tech. (CSE/IT), III Semester Database Management Systems Jitendra Rajpurohit.
CS3431: C-Term CS3431 – Database Systems I Introduction Instructor: Mohamed Eltabakh
Database System Concepts Introduction Purpose of Database Systems View of Data Data Models Data Definition Language Data Manipulation Language Transaction.
LECTURE TWO Introduction to Databases: Data models Relational database concepts Introduction to DDL & DML.
Building the Corporate Data Warehouse Pindaro Demertzoglou Lally School of Management Data Resource Management.
CIS 336 AID Your Dreams Our Mission/cis336aid.com
Entity- Relationship (ER) Model
Chapter 6 - Database Implementation and Use
Database Requirements and Design
Introduction To Database Systems
Accounting Information Systems 9th Edition
Database Systems Instructor Name: Lecture-12.
CS 174: Server-Side Web Programming February 12 Class Meeting
Database Fundamentals
Data Model.
Session - 6 Sequence - 1 SQL: The Structured Query Language:
Database Management Systems
Chapter 11 Managing Databases with SQL Server 2000
Lecture 23 CS 507.
Presentation transcript:

ITN MySQL Database Programming 1 Lecture 3 :Database Analysis and Design (I) ITN 170 MySQL Database Programming

ITN MySQL Database Programming 2 Objectives Understand the phases of the Database Development Process Explain what Conceptual Data Modeling and Database Design

ITN MySQL Database Programming 3 Business Requirements Operational System There is 6-steps Development cycle beginning from Business Requirements to Operational System. Data modeling and database design support the first 3 steps of the whole Development cycle. STRTATEGY ANALYSIS DESIGN TRANSITION PRODUCTION BUILD USER DOCUMENTATION

ITN MySQL Database Programming 4 Business Requirements Operational System STRTATEGY ANALYSIS The user and system requirements are gathered and analyzed. The expected information from this step would be a set of requirements that specify the whats of the system and user. A project plan and development time frame are specified at this time. (the documents are outlined and overview are provided) Step 1 & step 2: whats

ITN MySQL Database Programming 5 Business Requirements Operational System STRTATEGY ANALYSIS DESIGN The user requirements and system specifications are applied to create a design document consisting of an entity relationship diagram (ERD), flow charts, and so forth. The purpose of the design step is to convey the hows of the project. Programming languages (eg. SQL), Database Management Systems (eg. MySQL), coding, and naming standards are specified here. Step 3 (an important part): hows whats

ITN MySQL Database Programming 6 Business Requirements Operational System DOCUMENTATION STRTATEGY ANALYSIS DESIGN BUILD The design is converted from specifications and diagrams to actual executables and database structures. During this step, the as-built documents are written; these documents instruct users how to use the system and instruct production support how to support the application. ERDs are mapped to tables, columns, and relations. Step 4:

ITN MySQL Database Programming 7 Business Requirements Operational System STRTATEGY ANALYSIS DESIGN BUILD USER DOCUMENTATION The application is put through user-acceptance testing. This step could go back to any step up to Strategy Database memory usage and I/O balance, as well as contention tuning (DBA’s task). User may need to update their systems or modify their strategies (if system crashes). TRANSITION Stage 5:

ITN MySQL Database Programming 8 Business Requirements Operational System STRTATEGY ANALYSIS DESIGN BUILD USER DOCUMENTATION The project is passed off to production support and moves into a maintenance mode in which code is locked down and database changes are minimized. Once a project is in production, the activities around it move into the support and maintenance area. Usually there is no need to change the database structures because the transition testing stage is done. TRANSITION PRODUCTION Stage 6:

ITN MySQL Database Programming 9 Database Development Process Business Requirements Operational System Database development is a top-down, systematic approach that transforms business information requirements into an operational database. Analysis Design Build Strategy Entity-Relationship Data Model Entity Definitions Table Definitions Index, View, and Cluster Definitions Conceptual Data Modeling Database Design Database Build

ITN MySQL Database Programming 10 Database Development Process The Database Development Process is a vertical Development Cycle which has been successfully used and developed as an industry- standard since 1980’s. Business Requirements Operational System Analysis Design Build Strategy Conceptual Database Logical Database Conceptual Data Modeling Database Design Database Build Physical Database

ITN MySQL Database Programming 11 Business Information Requirements Top-down database development begins with the information requirements of the business. " I manage the Human Resources Department for a large company. We need to keep information about each of our company's employees. We need to track each employee's at first name, last name, job or position, hire date, and salary. For any employees on commission, we also need to track their potential commission. Each employee is assigned a unique number. Our company is divided into departments. Each employee is assigned to a department - for example, accounting, sales, or development. We need to know the department responsible for each employee and the department's location. Each department has a unique number - for example, accounting is 10 and sales is 30. Some of the employees are managers. We need to know each employee's manager, and the employees each manager manages." Example : Read the following, and take 15 minutes to think about the business requirements:

ITN MySQL Database Programming 12 Business Information Requirements’ Result " I manage the Human Resources Department for a large company. We need to keep information about each of our company's employees. We need to track each employee's at first name, last name, job, hire date, and salary. For any employees on commission, we also need to track their potential commission. Each employee is assigned a unique number. Our company is divided into departments. Each employee is assigned to a department - for example, accounting, sales, or development. We need to know the department responsible for each employee and the department's location. Each department has a unique number - for example, accounting is 10 and sales is 30. Some of the employees are managers. We need to know each employee's manager, and the employees each manager manages."

ITN MySQL Database Programming 13 Conceptual Data Modeling Overview Draw a diagram showing the possible columns you can get from the reading: EMPLOYEE DEPARTMENT

ITN MySQL Database Programming 14 Conceptual Data Modeling Overview  In Conceptual Data Modeling, define and model the things of significance about which the business needs to know or hold information, and the relationships between them.  An Entity-Relationship Data Model should accurately model the organization's information needs and support the functions of the business

ITN MySQL Database Programming 15 Conceptual Data Modeling Overview Example (continued): The following entity-relationship model represents the results of information requirements of the Human Resources Department. EMPLOYEE # * number * first name * last name o job * hire date o salary o mgr o commission o deptno DEPARTMENT # * number * name * location assigned to responsible for the manager of

ITN MySQL Database Programming 16 Database Design Overview  ERD and Relational Database Design: In Database Design, map the information requirements reflected in an Entity-Relationship Model into a relational database design (Map the columns in the ERD into the table instance charts).  Significance of using table instance charts: The Table Instance Chart for each relational table identifies the table's columns, primary key, unique key, and any provides a visual view of sample data.

ITN MySQL Database Programming 17 Col NameEMPNOFNAMELNAMEJOBHIREDATESALCOMMMGRDEPTNO Key Type Null/Unique Sample Data Col NameDEPTNODNAMELOC Table Name: DEPARTMENT Table Name: EMPLOYEE Key Type Null/Unique Sample Data

ITN MySQL Database Programming 18 Col NameEMPNOFNAMELNAMEJOBHIREDATESALCOMMMGRDEPTNO Key TypePK FK1FK2 Null/UniqueNN, UNN Sample Data7369MARYSMITHCLERK17-DEC HENRYFORDANALYST03-DEC SUEWARDSALESMAN22-FEB BOBBLAKEMANAGER01-MAY BOBKINGPRESIDENT17-NOV Col NameDEPTNODNAMELOC Key TypePK Nulls/UniqueNN, UNN 10ACCOUTINGNew York 20REASEARCHDALLAS 30SALESCHICAGO 40OPERATIONSBOSTON 50DEVELOPMENTATLANTA Table Name: DEPARTMENT Table Name: EMPLOYEE

ITN MySQL Database Programming 19 Database Build Overview In Database Build, create physical relational database tables to implement the database design. Example: The Structured Query Language (SQL) is used to create and manipulate relational databases. We will create the DEPARTEMNT and EMPLOYEE tables by using SQL statements. Log into the MySQL by using your user_id, and password at your Linux account.

ITN MySQL Database Programming 20 PS: The Structured Query Language (SQL) is used to create and manipulate relational databases. -- Create Table Department -- DROP TABLE department; CREATE TABLE department (deptno SMALLINT(2) NOT NULL PRIMARY KEY, dname CHAR(20) NOT NULL, loc CHAR(15) NOT NULL);

ITN MySQL Database Programming Create employee table DROP TABLE employee; CREATE TABLE employee (empnoSMALLINT(5) NOT NULL PRIMARY KEY, enameCHAR(15) NOT NULL, lnameCHAR(15) NOT NULL, jobCHAR(15), hiredateDATETIME NOT NULL, salNUMBER(7,2), commNUMBER(7,2), mgrSMALLINT(4), deptno SMALLINT(2) NOT NULL);