Presentation is loading. Please wait.

Presentation is loading. Please wait.

ERwin.

Similar presentations


Presentation on theme: "ERwin."— Presentation transcript:

1 ERwin

2 Main Screen

3 Create a New Model Create a new logical/physical model
2. Click “Logical/Physical” 1. Click “Create model” (or File -> New) 3. Configure the “Target Database” (In CS360, we’re using Oracle 11g)

4 Differences between Notations
Image from President Company max=1 min=0 min=1 Person Location max1 <Crow’s Foot>

5 Notations Two notations available Information Engineering (IE)
Integration DEFinition (IDEF) Use IE Notation IE notation To use IE Notation (in menu bar) Model → Model Properties Logical Physical IDEF1X notation Logical Physical

6 Information Engineering Notation

7 Entity Sets Entity set name Entity set Keys Attributes
Left click  attribute properties Entity set name Keys Attributes An independent entity set Entity set For relationships and weak entity sets A dependent entity set (Stars-in)

8 Entity Sets (Cont’d) Non-Identifying vs. Identifying Relationship
Non-Identifying relationship Independent Entity Sets Dependent Entity Sets

9 O: zero, |: one, crow’s foot: many
Relationships O: zero, |: one, crow’s foot: many relationships Example Movies Owns Studios Identifying relationship Many-to-many relationship Non-identifying relationship

10 Configure cardinality
Relationships Relationship properties Null allowed [c.f.) if not allowed ] Configure cardinality Three cardinality options zero, one or more (above example) One or more Zero or one

11 Relationships (Cont’d)
Convert many-to-many relationships to connecting entity sets 1. Click many-to-many relationship 2. Click “many-to-many transform” 3. Transformed relationship 4. (optional) change entity name

12 Subclasses 1. Click “sub-category” icon (isa relationship)
2. Click the superclass (optional) 4. Click is-a relationship (after clicking “sub-category” icon) (optional) 5. Click the subclass 3. Click the subclass

13 Subclasses choose the strategy for converting “isa-relationship”
Three options (see lecture note) 1. Supertype-Subtype Identity (E/R view) 2. Supertype-Subtype Rolldown (Similar to Object-oriented approach, but not equal) 3. Supertype-Subtype Rollup (Using NULL values to combine relations) 1. Click “isa” symbol! 2. Select transformation policy

14 DB Schema Construction (Cont’d)
Step 2 (cont’d) Three options 1. Supertype-Subtype Identify (E/R view) 2. Supertype-Subtype Rolldown (Similar to Object-oriented approach, but not equal) 3. Supertype-Subtype Rollup (Using NULL values to combine relations) Option 1 Option 2 Option 3

15 ER modeling Two different models Logical model Physical model
Conceptual modeling Independent of DBMS-specific implementations Only support subclasses and simple data types Physical model DBMS-specific modeling DBMS-specific data types

16 Buttons for generating DB schemas
ER modeling (Cont’d) Two different models (Cont’d) Buttons for generating DB schemas DB-specific Data types Logical model Physical model

17 DB Schema Construction
Step 1: Create a logical model Draw your ER diagram

18 DB Schema Construction (Cont’d)
Step 2: In physical model, choose a proper DB-specific data type for each columns in tables Right click an Entity  select Column Define data types for each column

19 DB Schema Construction (Cont’d)
Step 3: In physical model, generate a script for constructing schemas to the target DB (e.g. Oracle) Forward engineering (construct schema) Click “Preview button” to verify your SQL statements

20 ERwin Tip Display configuration Right click background
Check options you want to display on ER diagram  Entity, Table, Relationship … Here’s a tip solving a problem


Download ppt "ERwin."

Similar presentations


Ads by Google