The Relational Model J.G. Zheng May 15 th 2008. Introduction Edgar F. Codd, 1970 One sentence to explain relational database model: Data are organized.

Slides:



Advertisements
Similar presentations
Database Design: Normalization J.G. Zheng June 29 th 2005 DB Chapter 4.
Advertisements

The Relational Model DB Chapter 2 (and some from chapter 4, 5) J.G. Zheng June 27 th 2005.
Data Design The futureERD - CardinalityCODINGRelationshipsDefinition.
The Relational Model Chapter Two. 2 Chapter Objectives Learn the conceptual foundation of the relational model Learn the conceptual foundation of the.
Chapter 3 The Relational Model Transparencies © Pearson Education Limited 1995, 2005.
Chapter 3. 2 Chapter 3 - Objectives Terminology of relational model. Terminology of relational model. How tables are used to represent data. How tables.
Introduction to Relational Database ISYS 464. Introduction to Relational Model Data is logically structured within relations. Each relation is a table.
Chapter 14 Getting to First Base: Introduction to Database Concepts.
Database Design Chapter 3.
The Relational Database Model. 2 Objectives How relational database model takes a logical view of data Understand how the relational model’s basic components.
3 1 Chapter 3 The Relational Database Model Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel.
The Relational Model Codd (1970): based on set theory Relational model: represents the database as a collection of relations (a table of values --> file)
Thomas Connolly and Carolyn Begg’s
Database Architecture The Relational Database Model.
The Relational Database Model
1 Relational model concepts Key constraints Referential integrity constraint Steen Jensen, autumn 2013.
© Pearson Education Limited, Chapter 2 The Relational Model Transparencies.
Relational Model Session 6 Course Name: Database System Year : 2012.
Learningcomputer.com SQL Server 2008 – Entity Relationships in a Database.
Concepts of Database Management Seventh Edition Chapter 4 Keys and Relationship.
R ELATIONAL D ATA M ODEL Joe Meehean 1. R ELATIONAL D ATA M ODEL Data stored as a set of relations really just tables Tables related to one another through.
The Relational Model UC Berkeley Extension Copyright © 2008 Patrick McDermott.
System Design System Design - Mr. Ahmad Al-Ghoul System Analysis and Design.
1 Database & DBMS The data that goes into transaction processing systems (TPS), also goes to a database to be stored and processed later by decision support.
The Relational Model J.G. Zheng Jan 2010 CIS 8040 Database Management Systems.
The University of Akron Dept of Business Technology Computer Information Systems The Relational Model: Concepts 2440: 180 Database Concepts Instructor:
Relational Theory and Design
Database Systems: Design, Implementation, and Management Tenth Edition Chapter 3 The Relational Database Model.
Database Systems: Design, Implementation, and Management Ninth Edition Chapter 3 The Relational Database Model.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 3 The Relational Database Model.
THE RELATIONAL MODEL I IST 210: Organization of Data IST210 1.
Week 7-8 DBMS ER-Relational Mapping. ER-Relational Mapping.
The Relational Model. 2 Relational Model Terminology u A relation is a table with columns and rows. –Only applies to logical structure of the database,
NORMALIZATION. What is Normalization  The process of effectively organizing data in a database  Two goals  To eliminate redundant data  Ensure data.
* Database is a group of related objects * Objects can be Tables, Forms, Queries or Reports * All data reside in Tables * A Row in a Table is a record.
3 1 Chapter 3 The Relational Database Model Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
Database Design Chapter 9 Part-1: Concepts & Foreign Keys 1.
Howard Paul. Sequential Access Index Files and Data File Random Access.
CHAPTER 2 : RELATIONAL DATA MODEL Prepared by : nbs.
Concepts of Database Management Seventh Edition Chapter 4 Keys and Relationship.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 3 The Relational Database Model.
Chapter 3 The Relational Model. Objectives u Terminology of relational model. u How tables are used to represent data. u Connection between mathematical.
Normalization ACSC 425 Database Management Systems.
INFORMATION TECHNOLOGY DATABASE MANAGEMENT. A database is a collection of information organized to provide efficient retrieval. The collected information.
Chapter 4 The Relational Model Pearson Education © 2009.
Southern Methodist University CSE CSE 2337 Introduction to Data Management Chapter 2.
IT 5433 LM3 Relational Data Model. Learning Objectives: List the 5 properties of relations List the properties of a candidate key, primary key and foreign.
A Guide to SQL, Eighth Edition
Database, tables and normal forms
The Relational Database Model
Chapter 9 Part-1: Concepts & Foreign Keys
The Relational Model and Database Normalization
The Relational Model Chapter Two DATABASE CONCEPTS, 3rd Edition
Relational Databases.
Tables and Their Characteristics
Database Systems: Design, Implementation, and Management Tenth Edition
Chapter 4 Relational Model Characteristics
CSCI-100 Introduction to Computing
Data Base System Lecture 6: Relational Model
Chapter 9 Part-1: Concepts & Foreign Keys
Chapter 4 The Relational Model Pearson Education © 2009.
The Relational Database Model
Lingma Acheson Department of Computer and Information Science IUPUI
Design tools and techniques for a relational database system
DBMS ER-Relational Mapping
Chapter 4 The Relational Model Pearson Education © 2009.
Chapter 4 The Relational Model and Normalization
Database Systems: Design, Implementation, and Management
Presentation transcript:

The Relational Model J.G. Zheng May 15 th 2008

Introduction Edgar F. Codd, 1970 One sentence to explain relational database model: Data are organized in relations (tables), which are linked (relationship) by keys

Relation A relation is a two-dimensional table that has specific characteristics: The table consist of rows and columns Rows contain data about an entity instances All values in a row describes the same entity instance Columns contain data about attributes of the entity All values in a column are of the same kind

Relation (continued) Relations specific characteristics go on: Cells of the table hold a single value Each row is distinct Each column has a unique name The order of the rows is unimportant The order of the columns is unimportant

Non-Relation Examples

Relation Examples

Relation Terminology Contrast TableRowColumn *EntityRecordField Relation[Tuple]Attribute

Keys A key is one or more columns of a relation that is used to identify a record Primary key Foreign key

Primary Key Primary key The value of this key column uniquely identifies a single record (row) There is only one primary key for a table Composite key A key that contains two or more attributes (columns) Example: FirstName + LastName FirstName + LastName + BirthDate FirstName + LastName + BirthDate + BirthCity …

Relationship and Foreign Key Relationship defines how tables (relations) are linked Two tables are linked by a pair of keys The primary key of one table The foreign key in the linked table These two keys are of the same kind

Relationship Example Primary Key (PK) Foreign Key

Relationship Types One-to-one Example: students and GSU network accounts One-to-many Example: students and diplomas Many-to-many Example: students and professors

Referential Integrity Every value of a foreign key must match a value of the primary key For example (Premiere Products database) In Customer table, RepNum is a foreign key (linked to the Rep table where RepNum is the primary key). Then every value of RepNum in the Customer table must exist in the Rep table

Summary Understand three important concepts of relational database model Relation Keys Primary key Composite key Foreign key Relationship