1 / 13

Entities

Entities. Things about which you need to store data. One entity for each different thing. At least two attributes At least two occurrences Not a property of some other entity Not a derived quantity (like a report). Finding Entities. List things described in a business narrative

wlangley
Télécharger la présentation

Entities

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. Entities • Things about which you need to store data. One entity for each different thing. • At least two attributes • At least two occurrences • Not a property of some other entity • Not a derived quantity (like a report)

  2. Finding Entities • List things described in a business narrative • List things that are read from or written to in the process analysis of the system • Describe a record (occurrence) by listing the attributes it has • Be certain you need to store data

  3. Relationships • Relationships connect a record in one entity to one or more records in another entity (A recursive relationship connects a record to records in the same entity) • Relationships connect records (occurrences) not entities • Relationships do not change anything (they are not processes)

  4. Determining Relationships • Describe connections: • has a, orders a, contains a, etc. • on a common report page, line, etc. • Connect records, not attributes • Can be described by a passive phrase • Do not describe a change in values

  5. Cardinality • How many records could be connected to this one? • Two sided test.

  6. 1:N

  7. M:N • Associations • Associations with data • Associations that occur more than once

  8. ATTRIBUTE: A description or property of a given entity type. • Must depend on the entity key alone • Must contain information that we explicitly need • Must have the same data type for all entity occurrences

  9. TYPES OF ATTRIBUTES: • Composite or Simple (atomic) • Single valued or Multivalued (repeating group) Relational database models cannot represent multivalued attributes but objects and structured databases can. Repeating groups (sets of related multivalued attributes) usually represent entities or subclasses.

  10. Optionality(Referential Integrity) Records in a table that have a relationship with another table may be restricted by optionality requirements. • Relationship Optional • Relationship Mandatory (referential integrity enforced)

  11. Optionality A constraint should be mandatory only if the relationship must be known whenever a record is first entered. Most relationships are optional.

  12. Maintaining Integrity If a parent record is deleted then an optionality relationships can be maintained in several ways • Cascade delete • Cascade update • Cascade null

  13. Typical Patterns • Simple “Ownership” • Product Order • Appointment • Journal Entry • Component Parts

More Related