1 object-relational model object-oriented database system
TRANSCRIPT
1
Object-Relational ModelObject-Relational Model
• Object-Oriented database system• Object-Oriented database system
2
Object-Relational ModelObject-Relational Model
• Object-Oriented database system
A programming language with a type system that allows any data to be persistent and supports XIII Commandments
• Object-Oriented database system
A programming language with a type system that allows any data to be persistent and supports XIII Commandments
3
Object-Relational ModelObject-Relational Model
• Object-Relational database system• Object-Relational database system
4
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
• Object-Relational database system
A relational database system with:
5
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
6
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
7
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
8
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
– reference types
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
– reference types
9
Object-Relational ModelObject-Relational Model
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
– reference types
– inheritance
• Object-Relational database system
A relational database system with:
– user defined Abstract Data Types (ADT)
– type constructors
– object identity
– reference types
– inheritance
10
Object-Relational ModelObject-Relational Model
• Abstract Data Type (ADT) (B. Liskov, S. Ziles, 1976)
• Abstract Data Type (ADT) (B. Liskov, S. Ziles, 1976)
11
Object-Relational ModelObject-Relational Model
• Abstract Data Type (ADT) (B. Liskov, S. Ziles, 1976)
Combination of atomic data types and their associated methods
• Abstract Data Type (ADT) (B. Liskov, S. Ziles, 1976)
Combination of atomic data types and their associated methods
12
Object-Relational ModelObject-Relational Model
• Type constructor• Type constructor
13
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
14
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
15
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type )
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type )
16
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type )
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type )
17
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type ) set-of( base type)
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type ) set-of( base type)
18
Object-Relational ModelObject-Relational Model
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type ) set-of( base type) bag-of( base-type )
• Type constructor
A mapping of atomic data types and user-defined abstract data types into complex abstract data types
row( n1 : t1, n2 : t2, …, nk : tk ) where ni is a field name and ti is a type
list-of( base type ) array-of( base type ) set-of( base type) bag-of( base-type )
19
Object-Relational ModelObject-Relational Model
• Operations for constructed types• Operations for constructed types
20
Object-Relational ModelObject-Relational Model
• Operations for constructed types
Field extraction (dot operation)
• Operations for constructed types
Field extraction (dot operation)
21
Object-Relational ModelObject-Relational Model
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
22
Object-Relational ModelObject-Relational Model
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
23
Object-Relational ModelObject-Relational Model
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
Index reference
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
Index reference
24
Object-Relational ModelObject-Relational Model
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
Index reference
Other
• Operations for constructed types
Field extraction (dot operation)
Set and multiset operations
List operations
Index reference
Other
25
Object-Relational ModelObject-Relational Model
• Objects, object identifiers, reference types• Objects, object identifiers, reference types
26
Object-Relational ModelObject-Relational Model
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
27
Object-Relational ModelObject-Relational Model
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
Every tuple (row) can be given object identifier
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
Every tuple (row) can be given object identifier
28
Object-Relational ModelObject-Relational Model
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
Every tuple (row) can be given object identifier
Object identifier can be used to refer to it from elsewhere in data
ref(base type)
• Objects, object identifiers, reference types
In object-relational model every tuple (row) can be considered as object
Every tuple (row) can be given object identifier
Object identifier can be used to refer to it from elsewhere in data
ref(base type)
29
Object-Relational ModelObject-Relational Model
• Inheritance• Inheritance
30
Object-Relational ModelObject-Relational Model
• Inheritance
Inheritance allows to reuse and refine already defined types
• Inheritance
Inheritance allows to reuse and refine already defined types
31
Object-Relational ModelObject-Relational Model
• Inheritance
Inheritance allows to reuse and refine already defined types
Substitution principle:
Given a supertype A and a subtype B, it is always possible to substitute an object of type B into a legal expression written for objects of type B, without producing errors
• Inheritance
Inheritance allows to reuse and refine already defined types
Substitution principle:
Given a supertype A and a subtype B, it is always possible to substitute an object of type B into a legal expression written for objects of type B, without producing errors