DOC PREVIEW
Toronto CSC 340 - The Entity-Relationship Model

This preview shows page 1-2-3-26-27-28 out of 28 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

The Entity-Relationship Model -- 1Information Systems Analysis and Design csc3402002 John MylopoulosXV. The Entity-Relationship ModelThe Entity-Relationship ModelEntities, Relationships and AttributesCardinalities, Identifiers and GeneralizationDocumentation of E-R Diagrams and Business RulesThe Entity-Relationship Model -- 2Information Systems Analysis and Design csc3402002 John MylopoulosThe Entity Relationship Model The Entity-Relationship (ER) model is a conceptual data model,capable of describing the data requirements for a new informationsystem in a direct and easy to understand graphical notation. Data requirements are described in terms of a conceptual conceptual (or,(or, ER ER))schemaschema. ER schemata are comparable to class diagrams.The Entity-Relationship Model -- 3Information Systems Analysis and Design csc3402002 John MylopoulosThe Constructs ofthe E-R ModelAND/XORThe Entity-Relationship Model -- 4Information Systems Analysis and Design csc3402002 John MylopoulosEntities These represent classes of objects (facts, things, people,...) that haveproperties in common and an autonomous existence. City, Department, Employee, Purchase and Sale are examples ofentities for a commercial organization. An instance of an entity is an object in the class represented by theentity. Stockholm, Helsinki, are examples of instances of the entity City,and the employees Peterson and Johanson are examples ofinstances of the Employee entity. The E-R model is very different from the relational model in which it isnot possible to represent an object without knowing its properties (anemployee is represented by a tuple containing the name, surname, age,and other attributes.)The Entity-Relationship Model -- 5Information Systems Analysis and Design csc3402002 John MylopoulosExamples of EntitiesThe Entity-Relationship Model -- 6Information Systems Analysis and Design csc3402002 John MylopoulosRelationships They represent logical links between two or more entities. Residence is an example of a relationship that can exist between theentities City and Employee; Exam is an example of a relationshipthat can exist between the entities Student and Course. An instance of a relationship is an n-tuple made up of instances ofentities, one for each of the entities involved. The pair (Johanssen,Stockholm), or the pair (Peterson,Oslo),are examples of instances in the relationship Residence.The Entity-Relationship Model -- 7Information Systems Analysis and Design csc3402002 John MylopoulosExamples of RelationshipsThe Entity-Relationship Model -- 8Information Systems Analysis and Design csc3402002 John MylopoulosExample of Instances for ExamExamThe Entity-Relationship Model -- 9Information Systems Analysis and Design csc3402002 John MylopoulosWhat Does An E-R Diagram Really Mean?What Does An E-R Diagram Really Mean?CourseCourse and RoomRoom are entities. Their instances describe particular courses(e.g., CSC340S) and particular rooms (e.g., WB116).MeetsMeets is a relationship. Its instances describe particular meetings. Eachmeeting has exactly one associated course and roomCourseCourseCourseMeetsMeetsRoomRoomRoomCourse instancesCourse instancesCourse instancesRoom instancesRoom instancesRoom instancesMeets instancesMeets instancesMeets instancesThe Entity-Relationship Model -- 10Information Systems Analysis and Design csc3402002 John MylopoulosRecursive Relationships Recursive relationships are alsopossible, that is relationshipsbetween an entity and itself. Note in the second examplethat the relationship is notsymmetric. In this case it isnecessary to indicate the tworoles that the entity involvedplays in the relationship.The Entity-Relationship Model -- 11Information Systems Analysis and Design csc3402002 John MylopoulosTernary RelationshipsThe Entity-Relationship Model -- 12Information Systems Analysis and Design csc3402002 John MylopoulosAND/XOR for RelationshipsAND/XOR for RelationshipsOrderOrderOrderContainsContainsContainsPartPartPartRequestsRequestsRequestsServiceServiceServiceXORXOROrderOrderOrderFilledByFilledByFilledByShipmentShipmentShipmentGeneratesGeneratesGeneratesInvoiceInvoiceInvoiceANDAND““OrdersOrderseither order aeither order apart orpart orrequest arequest aservice, butservice, butnot bothnot both””““For any givenFor any givenorder,order,whenever therewhenever thereis at least oneis at least oneinvoice there isinvoice there isalso at least onealso at least oneshipmentshipmentand vice versaand vice versa””The Entity-Relationship Model -- 13Information Systems Analysis and Design csc3402002 John MylopoulosOrderOrderOrderContainsContainsContainsPartPartPartRequestsRequestsRequestsServiceServiceServiceXORXORXORFilledByFilledByFilledByGeneratesGeneratesGeneratesShipmentShipmentShipmentInvoiceInvoiceInvoiceANDANDANDShipmentShipmentShipmentInvoiceInvoiceInvoiceGeneratesGeneratesGeneratesFilledByFilledByFilledByOrderOrderOrderContainsContainsContainsRequestsRequestsRequestsServiceServiceServicePartPartPartThe Entity-Relationship Model -- 14Information Systems Analysis and Design csc3402002 John MylopoulosAttributes These describe the elementary properties of entities or relationships. For example, Surname, Salary and Age are possible attributes ofthe Employee entity, while Date and Mark are possible attributes forthe relationship Exam between Student and Course. An attribute associates with each instance of an entity (or relationship)a value belonging to a set known as the domain of the attribute. The domain contains the admissible values for the attribute.The Entity-Relationship Model -- 15Information Systems Analysis and Design csc3402002 John MylopoulosAttribute ExamplesThe Entity-Relationship Model -- 16Information Systems Analysis and Design csc3402002 John


View Full Document

Toronto CSC 340 - The Entity-Relationship Model

Documents in this Course
Scoping

Scoping

10 pages

Load more
Download The Entity-Relationship Model
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view The Entity-Relationship Model and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view The Entity-Relationship Model 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?