1 / 13

Chapter 5 The Relational Data Model

Relational Model Concepts . The Relational Model of Data is based on the concept of a RelationA Relation is a two-dimensional tableThe columns of the table represent attributesThe rows of the table represent entities. Relational Model Concepts. A relation schema is the name and the list of attrib

bella
Download Presentation

Chapter 5 The Relational Data Model

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


    1. Chapter 5 The Relational Data Model By Yue Lu CS157B Spring 2008 Instructor: Dr.Lee

    2. Relational Model Concepts The Relational Model of Data is based on the concept of a Relation A Relation is a two-dimensional table The columns of the table represent attributes The rows of the table represent entities

    3. Relational Model Concepts A relation schema is the name and the list of attributes of a relation Grade (studentId, assignmentId, points, dateSubmitted) A tuple is a row of a table, one value for each attribute (101, 102, 92, 2/28/08)

    4. Model Concepts Domain D is a set of atomic values Atomic means that each value is indivisible Attribute A is the name of a role played by some domain Relation schema R is the specification of a relation Given by a name and list of attributes Degree of a relation is the number of attributes Relation (instance) r(R) of a relation schema A set of n-tuples, n is degree of relation schema

    5. Characteristics of Relational Model Relation is a set of tuples No ordering of tuples No duplicate tuples no two rows have all the same values Each attribute value is atomic So no multiple-valued or composite attributes called first normal form Each relation is a set of assertions Each represents a fact Some facts are about relationships

    6. Representing E-R Model as Relations Entity class ? Relation schema Entity ? row of table set of all entities of class ? table Attribute ? column definition (attribute) attribute value ? table element Relationship type ? relation schema attribute(s) of relation schema

    7. Example of Relation Schema and Table Figure 4.2 P75 Customer(accountID,lastName,firstName, street, city, state, zipcode, balance)

More Related