CM515100-1 Business Systems Analysis, Design and Construction BSADC - PowerPoint PPT Presentation

1 / 41
About This Presentation
Title:

CM515100-1 Business Systems Analysis, Design and Construction BSADC

Description:

To discuss the 3 main concepts used in Entity Modelling and Data Analysis ... Marple Mindy Miss F. Thatcher Margaret Ms F. PGM. 26. Attribute types and Attributes 1 ... – PowerPoint PPT presentation

Number of Views:168
Avg rating:3.0/5.0
Slides: 42
Provided by: philmick
Category:

less

Transcript and Presenter's Notes

Title: CM515100-1 Business Systems Analysis, Design and Construction BSADC


1
CM515100-1 Business Systems Analysis, Design
and ConstructionBSADC
  • Week 6

2
Relational Data Analysis 1 Entity Modelling a
top down approach
3
Last Week
  • Last week we looked at
  • Low Level DFDs - DFD2
  • Elementary Process Descriptions

4
Data Flow Diagrams - DFDs
  • The symbols - basic outlines

5
Whats missing from the so far?
  • DFDs identify and specify
  • Data Flows
  • Activities, Processes, Functions
  • Data Stores
  • They DONT identify and specify the structure of
    data stores (data tables)

6
Objectives
  • To discuss the 3 main concepts used in Entity
    Modelling and Data Analysis
  • Establish those entities that are important to a
    particular system
  • Understand the relationships between those
    entities
  • Learn the associated structured modelling
    techniques the notation

7
The Three main Concepts
  • 1. The Entity
  • (please dont confuse with external entities)
  • 2. The Relationship (between entities)
  • 3. The Attribute (belonging to an entity)

8
An Elementary Example
Student Number Student Name Street
Address Town Post Code Telephone
Module Number Module Name Module
Leader Level Cats Points
9
1. The Entity
  • Is something we will need to hold data about
    within the system
  • The context of the organisation determines
    whether an entity has significance or importance
    eg
  • To a hospital
  • Patient, Doctor, Clinic, Ward
  • To a Delivery Company
  • Driver, Vehicle, Consignor, Consignee,
    Consignment
  • To a University
  • Student, Lecturer, Lecture, Room, Module,
    Employee

10
Drawing an entity
This is the symbol for the student entity
Student
Draw the symbol for the module entity
11
2. The Relationship 1
  • There are relationships between entities
  • The relationship can be illustrated by a joining
    word or phrase
  • Entity Entity
  • Customer places Orders
  • Hotel has Rooms
  • Guest makes Bookings
  • Student registers for Modules

12
Adding a relationship
This is the notation for the relationship
Draw the relationship between student and module
13
The Relationship 2
  • Sometimes an entity can have a relationship with
    itself, for example,
  • Entity Entity
  • Person is married to Person
  • Employee reports to Employee
  • Product made from a Product

is made of
Product
14
The notation an example so far
15
The Notation a further example
  • There are different types of relationships

16
Degrees of relationship
  • Relationships between entities are more detailed
    than first appears
  • One to One (11)
  • Customer has only one and only one account
  • One to many (1N)
  • Customer may have many bank accounts
  • Hotel has many rooms
  • Many to Many (MN)
  • Project has many workers
  • Worker works on many projects

17
Modelling Degrees of relationship 1
One to One (11)
18
Modelling Degrees of relationship 2
Many to Many (MN)
19
Intersection (or Link entity)
This gives rise to ambiguity of file structure
A more practical model is
20
Optionality
  • A relationship between two entities can also be
    mandatory or optional
  • Mandatory - a customer must have placed an
    order to be a customer
  • - hotel must have a room
  • Optionality - a bus may have a passenger
  • - a hotel room may have a guest

21
Modelling Optionality 1
  • Mandatory
  • Contingent

22
Modelling Optionality 2
  • Optional

Order item
Invoice item
may
may
23
Exclusivity
  • Some entities show links between two other
    entities - where the two links are mutually
    exclusive

Room
Bedroom
Bathroom
Living Room
Living Room
24
Adding Attributes
25
  • Entities have attributes (data items)
  • Attributes record something about an entity
  • For example - The entity PERSON
  • Surname First name Title Gender
  • Smith John Mr M
  • Jones Davy Mr M
  • Marple Mindy Miss F
  • Thatcher Margaret Ms F

26
Attribute types and Attributes 1
  • Be careful when you read the terms attribute type
    and attribute they are not the same thing
  • Attribute types will translate into the fields of
    a record on a data table
  • Attributes are the values or properties that
    identify or describe an entity occurrence

27
Attribute types and attributes 2
  • Entity Type Attribute Type Attribute
  • Department Dept Name Accounts
  • Building Canary Wharf
  • Location Floor 3
  • Dept Head Attila the Hun
  • Cost Centre Code ACC3

28
Getting started
  • What are the data items associated with the
    following LDS diagram?

29
The Student
  • Entity Type Attribute Type Attribute
  • Student Student Name Jones
  • Street Address Leek Road
  • Town Stoke-on-Trent
  • Post Code ST4 2DE
  • Telephone 294303

30
The Module
  • Entity Type Attribute Type Attribute
  • Module Module Name SSAT
  • Module Leader A Lecturer
  • Level 1
  • Cats Points 10

31
The Data items identified
32
Identifying occurrences of entities
  • Each occurrence of an entity should be uniquely
    identified in some way
  • Imagine the British Gas data base that used only
    surnames to identify account holders
  • There would be 100,000 account holders called
    Jones in this country
  • Even if we used the given names there would still
    be considerable duplication
  • It would be impossible to find the right account
    by name alone

33
Keys and Secondary keys
  • Key
  • a key is a data item used to identify a
    particular occurrence of an entity. It may not be
    unique so several entity occurrences may have the
    same key
  • your surname is an example of a key
  • Secondary Key
  • a secondary key does not uniquely identify an
    entity but helps to further identify an entity
    occurrence
  • your given name is a secondary key

34
Primary and Compound Keys
  • Primary Key
  • a primary key is a key consisting of a data item
    that uniquely identifies an entity occurrence
  • your national insurance number is unique
  • as is your passport number
  • a gas bill number is unique
  • as is a car registration
  • Compound keys
  • this is a primary key that is made up of two data
    items
  • room number and date booking reference
  • also there are Foreign and Composite keys

35
Foreign Keys
  • Foreign Key
  • An attribute in on table that is a primary key in
    another
  • More later

36
Adding a Primary Key
37
Getting it right
Is this right?
The real situation is
38
Putting it right
We need a link entity - less ambiguity
Student
Module
Student Number Student Name Street
Address Town Post Code ST4 2DE Telephone
Stud/Mod
Module Number Module Name Module
Leader Level Cats Points
Student Number Module number Date
enrolled Grade achieved
Foreign Keys
More about this soon
39
Self Study
  • Read Mastering Systems Analysis and Design -
    pages 67 to 78
  • Do exercises 5.8.1 to 5.8.7
  • Read handout

40
Next week
  • Data Optimisation

41
Tutorial
  • The college case study
  • The library case study
Write a Comment
User Comments (0)
About PowerShow.com