Introduction to information systems T. Cornford, M. Shaikh is1 060 2013


Download 0.65 Mb.
Pdf ko'rish
bet26/68
Sana01.03.2023
Hajmi0.65 Mb.
#1241862
1   ...   22   23   24   25   26   27   28   29   ...   68
Bog'liq
T. Cornford, M. Shaikh-13

Film
Cinema
0..*
0..*
Figure 2.1: A simple class diagram for films and cinemas.
The label 0..* at each end of the association in Figure 2.1 means that there 
can be zero, 1 or more films showing at a particular cinema (the cinema 
may be closed this week for redecoration), and that there can be zero, 1 
or more cinemas showing a particular film. The key to database analysis 
is to be able to think about such associations and how they are expressed 
accurately in the class diagram. The ‘many to many’ relationship in Figure 
2.1 above, which is how the world looks at first sight, becomes resolved 
into the idea of a new class called ‘Showing’ which allows us to specify a 
particular film being shown at a particular cinema at a particular time– 
hence the simple 1 at one end of the associations shown in Figure 2.2 
below. 
As an exercise explain what change you would make to the diagram in 
Figure 2.2 if a single showing could include up to four separate films. To 
get to the full answer to this question will require that you have studied 
Chapter 8, but even if this is your first read through the subject guide, you 
should be able to take the first steps to allow for this detail to be faithfully 
recorded in the class diagram.
Film
Title
Director
Length
Rating
Showing
Day
Time
Cinema
Name
Phone no
Address
0..*
0..*
1
1
Figure 2.2: A class diagram for films, showings and cinemas.


IS1060 Introduction to information systems
24
Chapter 8 of this guide contains a lot more neccessary detail about 
analysing and designing databases, but the two diagrams above should 
give you a basic understanding of the task, and an informal introduction 
to the class diagram. Please note also that the example used in Chapter 
8 of this guide (a database of customer orders for various products) is 
commonly used in textbooks (see for example Laudon and Laudon (2013) 
Section 6.2). It is a fairly complex class diagram but an excellent one for 
the purpose of illustrating the task of analysing and designing a database. 
It is not, however, appropriate as the main basis for your database project. 
This is for two reasons. First, you will have used it to understand the topic, 
it is not your own idea. Second, given that this is a complete ‘solution’ 
to a common database application (a business processing orders from 
customers), and is already fully worked out by somebody else, using it 
means that you do not have the opportunity to demonstrate your ability as 
a database analyst and designer. Thus the Examiners will give low 

Download 0.65 Mb.

Do'stlaringiz bilan baham:
1   ...   22   23   24   25   26   27   28   29   ...   68




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling