Professional Documents
Culture Documents
Part 2: ER-Diagrams
in Oracle Designer
References:
• Barker: CASE*Method, Entity Relationship Modelling.
Addison-Wesley, 1990, ISBN 0-201-41696-4, ca. $61.
• Koletzke/Dorsey: Oracle Designer Handbook, 2nd Edition.
ORACLE Press, 1998, ISBN 0-07-882417-6, ca. $40.
• A. Lulushi: Inside Oracle Designer/2000.
Prentice Hall, 1998, ISBN 0-13-849753-2, ca. $50.
• Oracle/Martin Wykes: Designer/2000, Release 2.1.1, Tutorial.
Part No. Z23274-02, Oracle, 1998.
• Oracle Designer Model, Release 2.1.2 (Element Type List).
• Oracle Designer Online Help System.
• Oracle Designer Forum:
[http://forums.oracle.com/forums/thread.jspa?messageID=2386897]
• Oracle Developer Tools:
[http://www.oracle.com/technology/products/developer-tools/index.html]
• Teorey: Database Modeling & Design, 3rd Edition.
Morgan Kaufmann, 1999, ISBN 1-55860-500-2, ca. $32.
• Elmasri/Navathe: Fundamentals of Database Systems, 2nd Ed.,
Appendix A, “Alternative Diagrammatic Notations”.
• Rauh/Stickel: Konzeptuelle Datenmodellierung (in German), Teubner, 1997.
Objectives
After completing this chapter, you should be able to:
• write a short paragraph about Oracle Designer.
What is it, what are its main components, and how does it support
the design and development of database application systems?
Overview
' $
1. Oracle Designer
& %
Repository (1)
• The set of all tables etc. used for storing this in-
formation is called the repository.
The Designer 2.1.2 repository contains 1532 objects, of which are
107 tables, 273 views, 149 indexes, 64 constraints, 17 triggers, 9 se-
quences, 472 packages, 510 package bodies.
In Designer 6i, the repository consists of 5549 (6i Release 1) or
5561 (Release 2 and 3) objects. Release 1: 392 tables, 757 indexes,
720 views, 1008 constraints, 1025 triggers.
Repository (2)
Repository (3)
Schema:
Instance: ?
Schema:
Instance: ?
Repository (4)
Repository (5)
Repository (6)
Repository (7)
• Prior to version 6i, the repository was used only for
Oracle Designer, and had no version control.
• Then there was a big change:
Oracle Repository and the Software Configurati-
on Manager (Oracle SCM) became an indepen-
dent product (part of the Developer Suite),
which was intended for arbitrary software pro-
jects, and used e.g. in JDeveloper 9i and 10g.
Version control (branching / merging versions)
and configuration management was added.
Repository (8)
• However, it seems that many software developers
preferred CVS or subversion.
• Therefore, starting from JDeveloper 10.1.3, the
built-in support for Oracle SCM was removed.
• Bugfixes in SCM 10g are still done, it remains a
supported product, but no new features are added.
• Nevertheless, one cannot fully understand the re-
pository from its use in Oracle Designer alone.
Some features of the Repository are not used in Oracle Designer
(e.g., folders, see below). This might be confusing, because they are
available in general repository tools (applied also in Oracle Designer).
Repository (9)
• Version control in the repository can be enabled or
disabled.
It is installed with version control disabled. The repository owner can
enable it, but then it can never be disabled again.
Repository (10)
• Objects in the repository are structured into con-
tainers (like a directory tree in the file system).
• Containers can be of two types:
Application System: Only this type is supported
for modelling elements in Oracle Designer.
The name “Application System” for a container type might seem
strange. It has historical reasons: In older versions of the Designer,
the repository could store several application systems (projects).
Overview
1. Oracle Designer
' $
ER-Model Variants
• Relationship attributes.
Also in this case, one must turn the relationship into an (association)
entity with two binary relationships without attributes.
• Multivalued/structured attributes.
Multivalued attributes can be handled with weak entities. For struc-
tured attributes, the components can be declared as attributes.
• Non-disjoint specialization.
INSTRUCTOR
# NAME
* ROOM
◦ PHONE
& %
INSTRUCTOR
# NAME
* ROOM
◦ PHONE
e.g. Brass
& %
Relationships (1)
INSTRUCTOR teacher of
HH
COURSE
taught by H
& % & %
Relationships (2)
' $ ' $
INSTRUCTOR teacher of
HH
COURSE
taught by H
& % & %
' $ ' $
' $ ' $
teacher of
INSTRUCTOR
HH
COURSE
taught by H
& % & %
' $ ' $
teacher of
INSTRUCTOR
H
COURSE
taught by H
H
& % & %
Cardinalities (1)
• In Oracle Designer:
' $ ' $
COURSE H
HH
taught by INSTRUCTOR
teacher of
& % & %
Cardinalities (2)
COURSE H
HH
taught by INSTRUCTOR
teacher of
& % & %
Cardinalities (3)
• In Oracle Designer:
' $ ' $
COURSE H
H
taught by
H INSTRUCTOR
teacher of
& % & %
Here an instructor must teach at least one course, and can teach any
number of courses. A course does not require an instructor, but can
have at most one.
Cardinalities (4)
• In Oracle Designer:
' $ ' $
INV_ITEM H
HHfor INVOICE
composed of
& % & %
Cardinalities (5)
• In Oracle Designer:
' $ ' $
ORDER H
HH
placed for
PRODUCT
HH
subject of H
& % & %
Every purchase order must be for at least one product, but can be for
many products. One product can be ordered in many purchase oders.
There can be new products that are not yet ordered.
Cardinalities (6)
• In Oracle Designer:
' $ ' $
STUDENT H
HH
registered for
COURSE
H
taken by HH
& % & %
Cardinalities (7)
Cardinalities (8)
Department
H
HH led by HH Employee
H
HH
H
H
H
• In Oracle Designer:
' $ ' $
Cardinalities (9)
• In Oracle Designer:
' $ ' $
Cardinalities (10)
• In Oracle Designer:
' $ ' $
Recursive Relationships
COURSE H
H
H
has precondition
& %
AA
A
is precondition for
Overview
1. Oracle Designer
Overview
1. Oracle Designer
Abbreviation
Meaning (help text)
Domains (1)
Domains (2)
Domains (3)
Domains (4)
Domains (5)
Domains (6)
Domains (8)
Domains (10)
Format/Attribute vs. Datatype/Column:
• A domain definition contains information at the
ER-level (Format) as well as about the implemen-
tation (Datatype).
The documentation also mentions that the datatype can also be used
for application program variables, but then it depends on the program-
ming language. The type system of languages like C are quite different
from the SQL type system.
Domains (11)
Dynamic List:
• If this is checked, the possible values will be retrie-
ved at runtime from a lookup table.
This makes it easy to change the possible values of the enumeration
type later: One can simply insert a new value into the lookup table.
' $
ROOM
BUILDING
home of # NUMBER
# NAME
HH
H
∗ TYPE
◦ YEAR BUILT contained in
◦ CAPACITY
& %
& %
' $
Wrong! ROOM
BUILDING # NAME
home of
# NAME # NUMBER
HH
H
Name
Email
Points
No
MPoints
◦ EMAIL submitted by
& % SOLUTION
' $
∗ POINTS
EXERCISE
subject of
# NUMBER
HH
H
& % & %
Specialization (1)
Specialization (2)
' $ ' $
INSTRUCTOR COURSE
teacher of
# NAME # CRN
H
H
H
taught by
∗ EMAIL ∗ TITLE
' $ & %
' $
FACULTY member of COMMITTEE
H
HH
∗ PROF TYPE
H
HH
# CNAME
& %
composed of
& %
' $
EXTERNAL
◦ AFFILIATION
∗ ADDRESS
& %
& %
Specialization (3)
Specialization (4)
• Example, continued:
Both types of instructors can teach courses.
Only faculty members can serve on committees.
• In general, specialization can be distinguished in:
Disjoint: It is not possible that an instructor is at
the same time a faculty member and an external
teacher. Oracle Designer only supports this case.
Overlapping: Objects of the superclass can be in
more than one subclass at the same time (then
they do not have a unique type: uncommon).
Specialization (5)
Specialization (6)
Specialization (7)
Specialization (8)
Generalization
Arcs (1)
COURSE @
v
taught by
FACULTY MEMBER
H
HH
teacher of
& %
' $
v
taught by
EXTERNAL INST
H
HH
teacher of
& %
& %
Arcs (2)
Arcs (3)
Overview
1. Oracle Designer
Attribute Definition
Half a page per attribute, attributes are sorted by entity types, a
new page is started for a new entity type.
Attributes in Domain
Table with one row per attribute in a domain, ordered by domain.
System Glossary
Descriptions of entity types.
• One can also specify the sort order e.g. within the
“Entities” section. and select which properties are
shown in the proterty palette.