v
To the memory of Brian.
vii
Contents
Preface xiii
Who Should Read This Book? xiii
What You Will Find xiv
Comparison with Other Books xv
Acknowledgments xvi
Chapter 1 Introduction 1
1.1 What Is a Model? 1
1.2 Modeling Notation 1
1.3 What Is a Pattern? 2
1.4 Why Are Patterns Important? 3
1.5 Drawbacks of Patterns 4
1.6 Pattern vs. Seed Model 4
1.7 Aspects of Pattern Technology 5
1.8 Chapter Summary 6
Bibliographic Notes 6
References 7
Part I: Mathematical Templates 9
Chapter 2 Tree Template 11
2.1 Hardcoded Tree Template 12
2.2 Simple Tree Template 15
2.3 Structured Tree Template 19
2.4 Overlapping Trees Template 23
2.5 Tree Changing over Time Template 27
2.6 Degenerate Node and Edge Template 31
2.7 Chapter Summary 33
viii
Bibliographic Notes 34
References 34
Chapter 3 Directed Graph Template 36
3.1 Simple Directed Graph Template 37
3.2 Structured Directed Graph Template 40
3.3 Node and Edge Directed Graph Template 45
3.4 Connection Directed Graph Template 48
3.5 Simple DG Changing over Time Template 52
3.6 Node and Edge DG Changing over Time Template 56
3.7 Chapter Summary 60
Bibliographic Notes 62
References 62
Chapter 4 Undirected Graph Template 63
4.1 Node and Edge Undirected Graph Template 64
4.2 Connection Undirected Graph Template 66
4.3 Undirected Graph Changing over Time Template 69
4.4 Chapter Summary 73
Chapter 5 Item Description Template 74
5.1 Item Description Template 74
5.2 Homomorphism Template 78
5.3 Chapter Summary 82
Bibliographic Notes 83
References 83
Chapter 6 Star Schema Template 84
6.1 Star Schema Template 84
6.2 Chapter Summary 89
Bibliographic Notes 89
References 90
Chapter 7 Summary of Templates 91
Part II: Antipatterns 95
Chapter 8 Universal Antipatterns 97
8.1 Symmetric Relationship Antipattern 97
8.2 Dead Elements Antipattern 99
8.3 Disguised Fields Antipattern 100
8.4 Artificial Hardcoded Levels Antipattern 101
8.5 Excessive Generalization Antipattern 103
8.6 Disconnected Entity Types Antipattern 104
8.7 Modeling Errors Antipattern 104
8.8 Multiple Inheritance Antipattern 105
Contents ix
8.9 Paradigm Degradation Antipattern 106
8.10 Chapter Summary 109
Bibliographic Notes 109
References 110
Chapter 9 Non-Data-Warehouse Antipatterns 111
9.1 Derived Data Antipattern 111
9.2 Parallel Attributes Antipattern 114
9.3 Parallel Relationships Antipattern 116
9.4 Combined Entity Types Antipattern 116
9.5 Chapter Summary 118
Part III: Archetypes 119
Chapter 10 Archetypes 121
10.1 Account 121
10.2 Actor 122
10.3 Address 124
10.4 Asset 124
10.5 Contract 125
10.6 Course 126
10.7 Customer 127
10.8 Document 128
10.9 Event 130
10.10 Flight 131
10.11 Item 133
10.12 Location 134
10.13 Opportunity 135
10.14 Part 136
10.15 Payment 137
10.16 Position 138
10.17 Product 139
10.18 Role 140
10.19 Transaction 141
10.20 Vendor 142
10.21 Chapter Summary 142
Bibliographic Notes 144
References 146
Part IV: Identity 147
Chapter 11 Identity 149
11.1 Intrinsic Identity 149
11.2 Names 151
x
11.3 Surrogate Identity 152
11.4 Structured Fields 152
11.5 Master Applications 153
11.6 Merging Data 153
11.7 Chapter Summary 154
Bibliographic Notes 155
References 155
Part V: Canonical Models 157
Chapter 12 Language Translation 159
12.1 Alternative Architectures 159
12.2 Attribute Translation in Place 160
12.3 Phrase-to-Phrase Translation 160
12.4 Language-Neutral Translation 163
12.5 Chapter Summary 167
Bibliographic Notes 167
References 167
Chapter 13 Softcoded Values 168
13.1 UML Model 168
13.2 IDEF1X Model 171
13.3 Architecture 171
13.4 Softcoding Variations 175
13.5 Chapter Summary 185
Bibliographic Notes 185
References 185
Chapter 14 Generic Diagrams 186
14.1 Generic Diagram Examples 186
14.2 Diagram Subject Area 187
14.3 Model Subject Area 189
14.4 Model–Diagram Binding Subject Area 193
14.5 DiagramType Subject Area 193
14.6 Diagram Example, Revisited 194
14.7 Chapter Summary 197
Bibliographic Notes 197
Chapter 15 State Diagrams 198
15.1 State Diagrams 198
15.2 Scenarios 200
15.3 Chapter Summary 202
Bibliographic Notes 202
References 202