Upcoming SlideShare
×

# 05 Transformation

593 views

Published on

Published in: Education
0 Likes
Statistics
Notes
• Full Name
Comment goes here.

Are you sure you want to Yes No
• Be the first to comment

• Be the first to like this

Views
Total views
593
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
5
0
Likes
0
Embeds 0
No embeds

No notes for slide

### 05 Transformation

1. 1. Transformation of ERMs into Relational Schemas<br />
2. 2. Initial Situation<br />Initial Situation: 3 Entity Types A, B und C<br />
3. 3. Transformation Rules ERM  Tables<br />Transformation Rules<br />Describethetransformationfrom ERM modelsintorelations (tables)<br />Are not alwaysunambiguous<br />Simple Example: (x,n)-(x,n)-Relation (x=0 v x=1)<br />
4. 4. (1,1)-(x,n)-Relation (x=0 v x=1)<br />
5. 5. (0,1)-(x,n)-Relation (x=0 v x=1)<br />
6. 6. (0,1)-(x,n)-Relation (x=0 v x=1)<br />
7. 7. (0,1)-(0,1)-Relation<br />
8. 8. (0,1)-(0,1)-Relation<br />
9. 9. (1,1)-(1,1)-Relation<br />Note: Itisnecessarytohave a triggerfornewentriesthatenforces an entry in thesecondrelation, as well. <br />
10. 10. (1,1)-(1,1)-Relation<br />Avoid (1,1)-(1,1) relations<br />Better: Modelling as attributes<br />
11. 11. (0,1)-(1,1)-Relation<br />
12. 12. Remark: (1,x)-Relations (x={1,..,n})<br />Example: (1,n)-(0,n)-Relations<br />
13. 13. Remark: (1,x)-Relation (x={1,..,n})<br />Example: (1,n)-(0,n)-Relation<br />
14. 14. Remark: (1,x)-Relation (x={1,..,n})<br />Example: (1,n)-(0,n)-Relation<br />
15. 15. Generalization/Specialization<br />How will Generalization/Specialization be modelled in Relations, meaning in Tables? <br />
16. 16. Generalization/Specialization (N,P)<br />
17. 17. Generalization/Specialization (N,T)<br />Tosomeextend<br />
18. 18. Generalization/Specialization (D,P)<br />Tosomeextend<br />
19. 19. Generalization/Specialization (D,T)<br />Tosomeextend<br />
20. 20. Triple Relationship Type<br />Entries are arbitrary, as long as they are unique entries in A, B, and C.<br />
21. 21. Reinterpreted Relationship Type (1/2)<br />New entries not arbitrary. Theyaredependenton alreadyexistingentries in AB!<br />
22. 22. Reinterpreted Relationship Type (2/2)<br />Entries not arbitrary, because #C is Foreign Key<br />
23. 23. Transformation of ERMs into Relational Schemas<br />