Representing Information - PowerPoint PPT Presentation

About This Presentation
Title:

Representing Information

Description:

Logical: in terms that a relational database system will understand (close to ... An abstraction of the object that contains those characteristics important to ... – PowerPoint PPT presentation

Number of Views:46
Avg rating:3.0/5.0
Slides: 22
Provided by: Dep53
Category:

less

Transcript and Presenter's Notes

Title: Representing Information


1
Representing Information
2
Data Models
  • A data model is a precise description of
    information content
  • Types of data models
  • Conceptual (high-level) in terms that users will
    understand
  • Logical in terms that a relational database
    system will understand (close to the way data is
    stored)
  • Physical (low-level, how data is actually
    stored) in terms of the underlying computer
    hardware and operating system (memory/file
    system)

3
Data Models
  • A Schema is a data model that is intended to be
    used with a specific database system
  • External schemas are defined for the users of a
    database
  • Logical schema defines the representation as a
    collection of tables that are stored in a
    database server
  • Internal schema defines the representation used
    by the database server to store the tables in
    memory or files

4
Data Models
  • Distinction between a schema and actual database
    intension vs. extension
  • Populating a database

5
Requirements
  • In this phase database designers gather
    information about the database system in need
  • Database designers model the database according
    to user requirements
  • Database attributes and characteristics conform
    to users actual vocabulary

6
Organizing Information
  • Entity
  • An abstraction of the object that contains those
    characteristics important to the information
    system
  • Entity class
  • The common characteristics that represent a set
    of entities
  • Attribute
  • A characteristic/property that helps to describe
    an object
  • Attribute value
  • The value of a particular characteristic

7
Organizing Information
  • Examples
  • Entity A customer, or the characteristics of a
    customer that are of interest
  • Entity class/type All of the potential
    customers, or the information about them
  • Attribute hair color or last name
  • Attribute value hair color is brown or last name
    is Breaux

8
Examples of Entity Classes
9
Attributes
  • An attribute has Name, Type, Restriction,
    Description
  • Domain of an attribute set of all possible
    values
  • Attribute
  • Single valued /simple/atomic
  • Multi-valued (each element is a possible value)
    college degree, car color
  • Composite (the whole is one value) consists of
    several atomic attributes (date, address)

10
Examples
11
Key Attributes
  • A key attribute is an attribute that uniquely
    identifies a single entity within the class
  • Examples
  • Employee SSN
  • Book ISBN
  • Customer AccountId
  • A key may be a composite attribute Full Name

12
Attribute Constraints
  • Key Constraint The system respects this
    constraint by rejecting an entity with an
    existing key
  • Null Constraint the value can (not) be
    NULL(unknown, not applicable)
  • Derived value not entered but computed based on
    other attributes values

13
Relationships
  • A relationship type between 2 entity classes
    represents the possibility that two entities may
    be related (x-product)
  • A customer may rent a video
  • A relationship (or relationship instance) is a
    connection between 2 entities (actual tuple)
  • Customer Jane Block rents the video with videoId
    90987
  • To maintain flexibility in relationships,
    relationship types are not defined as attributes
  • The customer accountId is not an attribute of the
    Video entity class

14
Example (Customer and Video)
15
Constraints on Relationships
  • A relationship type may be limited in how many
    relationships an object may have
  • The cardinality of a relationship type may be
  • One-to-one Each object of a class may have no
    more than one object of the other class
  • One-to-many One of the classes allows and entity
    to have any number of related entities, but the
    other class restricts its entities to be related
    to no more than one entity.
  • Many-to-many Entities of both classes may have
    any number of related entities of the other
    class.

16
Other Constraints
  • Min/Max constraints
  • Mandatory Participation Constraint and Optional
    Participation Constraint

17
Higher-order relationships
  • A relationship can involve more than two
    entities
  • Example Store-Video-Supplier relationship

18
Example(Case in Point)
  • Determining entity classes, attributes and
    relationship types for BigHit Online video sales
  • Process
  • Evaluate statement of goals for information
    system
  • Define entity classes
  • Define attributes for entity classes
  • Define relationship types
  • Determine cardinalities of relationship roles
  • Add attributes to relationship types as necessary
  • Evaluate entity classes, attributes, and
    relationship types for clarity, accuracy, and
    completeness

19
Example
  • Statement of goals is highlighted to identify
    different kinds of information


20
Example
  • Entities
  • Customer (key account , last name, first name,
    address, email, credit card, password)Movie
    (key id, title, genre, length)Sale (key id,
    cost, date, credit card)Shopping Cart (key id,
    date)

21
Example
Write a Comment
User Comments (0)
About PowerShow.com