DOC PREVIEW
SJSU CS 157A - MichaelGobelChapter 4.1 Presentation

This preview shows page 1-2-3-4-5-6 out of 18 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 18 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 18 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 18 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 18 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 18 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 18 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 18 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

CS 157A: Intro to Database SysEnhanced Entity-Relationship (EER) Modeling: Superclass/Subclass RelationshipInter-entity class relationshipIntra-entity class relationshipSuperclass and SubclassBasic Properties of SC/scNew EER diagram notation for SC/scSpecialization / GeneralizationMore SpecializationTotal/Partial CompletenessMore Specialization: MultiplePredicateSpecialization HierarchySpecialization LatticeCategorizationWhich EER Construct?AggregationTHE ENDCS 157A: Intro to Database SysSummary of Chapter Section 4.1 of the textbook Data Modeling and Database DesignCopyright 2007 Thomson Course TechnologyPresentation compiled by Michael Goebel2007 September 06Enhanced Entity-Relationship (EER)Modeling: Superclass/Subclass RelationshipGeneral Properties of Superclass/SubclassSpecialization and GeneralizationSpecialization HierarchySpecialization LatticeCategorizationAppropriate EER ConstructAggregationInter-entity class relationshipYou enter a store to buy a piece of furnitureStore and Furniture: different independent object types (aka entity types)Store has Furniture (has-a relationship)STORESellsFURNITUREIntra-entity class relationshipNeed to furnish your new apartmentYou want a table, chairs, bed, etc.These possess some common propertiesTable/Chair/Bed is Furniture (is-a relationship)FURNITURETABLECHAIRBEDSuperclass and SubclassNo relationship type between Furniture and Chair/Bed/TableFurniture can be many different thingsFurniture is Superclass (SC)Chair/Bed/Table is Subclass (sc)CHAIRBEDTABLEFURNITUREBasic Properties of SC/scA Superclass/Subclass relationshipOne Superclass is related to one or more SubclassesA Subclass entity only belongs to 1 SuperclassA Superclass entity can belong to 1 or more (or none) SubclassesSubclass inherits all attributes of SuperclassSubclass can have its own attributesCardinality ratio 1:1 is understood to existNew EER diagram notation for SC/scTotal completenessPartial completenessDisjoint SubclassOverlapping SubclassesUnion of SuperclassesAggregation of SubclassesIdentifies a SubclassdOUAUSpecialization / GeneralizationSpecialization is the process of discovering the distinguishing attributes of any subgroups and creating SubclassesSpecialization is a top-down approach to SC/scGeneralization is the process of gathering all the common attributes shared by a group of entities and creating a SuperclassGeneralization is a down-up approach to SC/scMore SpecializationInclusion of a Superclass in the specialization is called a Completeness ConstraintCompleteness Constraint can be either Total or PartialTotal Specialization: every entity of the Superclass participates in the specialization relationship (shown with a solid line)Partial Specialization: 1 or more entities of the Superclass participates in the specialization relationship (shown with a dash line)Total/Partial CompletenessSTUDENT_ATHLETEFOOTBALLBASEBALL BASKETBALLOTotal completenessPartial completenessUUUMore Specialization: MultipleSTUDENT_ATHLETEFOOTBALLBASEBALL BASKETBALLOTotal completenessPartial completenessUUUCAPTAINUTEAMPredicateHow to directly determine the membership of a SubclassThru the use of a defining predicateStudent_Athlete Subclass membership are Sport_TeamsSTUDENT_ATHLETEFOOTBALLBASEBALLOUUCAPTAINTEAMSPORT_TEAMSFOOTBALLUBASEBALLSpecialization HierarchyAlready know that a Superclass can have one or more SubclassesThose Subclasses themselves can become Superclasses of other SubclassesThe structure of Superclass-Subclass-Superclass-Subclass-etc. is limited to an inverted treeLimitation is that a Subclass can only be related to one Superclass specializationSpecialization LatticeSimilar to the Specialization Hierarchy where a child (Subclass) is only allowed on parent (Superclass specialization)The child (Subclass) is allowed to have 2 or more parents (Superclass) as long as each parent is from a different Specialization.The Subclass then inherits all the attributes and relationship types from each parent, Multiple Type InheritanceCategorizationThe idea that there is only one Superclass is the overriding characteristic of the Specialization/Generalization constructWhen many Superclasses and a Subclass are tied together by a single relationship type this is known as CategorizationThe Subclass is known as the CategoryAn entity which belongs to the Category must also exist in only one of the SuperclassesWhich EER Construct?When to use Specialization/Generalization or CategorizationNot always easy to know: subjective and context specificIf Superclasses share many common attributes with same properties then Specialization/Generalization might work bestIf Superclasses don't share much attributes but have a common category they could identify with, then Categorization might work bestAggregationAggregation (to combine) is similar to Categorization except that it must have Total CompletenessAggregation plays the “is a part of” in a SC/sc relationshipPCHARDWAREOP_SYSAUTHE


View Full Document

SJSU CS 157A - MichaelGobelChapter 4.1 Presentation

Documents in this Course
SQL

SQL

18 pages

Lecture

Lecture

44 pages

Chapter 1

Chapter 1

56 pages

E-R Model

E-R Model

16 pages

Lecture

Lecture

48 pages

SQL

SQL

15 pages

SQL

SQL

26 pages

Lossless

Lossless

26 pages

SQL

SQL

16 pages

Final 3

Final 3

90 pages

Lecture 3

Lecture 3

22 pages

SQL

SQL

25 pages

Load more
Download MichaelGobelChapter 4.1 Presentation
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 MichaelGobelChapter 4.1 Presentation 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 MichaelGobelChapter 4.1 Presentation 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?