SlideShare a Scribd company logo
ADBMS
By:
Dabbal S. Mahara
2018
Traditional Data Models
 Traditional Data Models:
• Hierarchical
• Network (since mid-60’s)
• Relational (since 1970 and commercially since 1982)
 These traditional models have been quite successful in
developing the database technology required for many
traditional business database applications.
2
RELATIONAL MODEL
 Relations are the key concept, everything else is around relations
 Primitive data types, e.g., strings, integer, date, etc.
 Great normalization, query optimization, and theory
 What is missing?
• Handling of complex objects
• Handling of complex data types
• Code is not coupled with data
• No inheritance, encapsulation, etc.
3
Object-Oriented Database
 Relational model has certain limitations when more complex database
applications must be designed and implemented, like CAD/CAM, CIM,
scientific experiments, telecommunications, GIS, and multimedia.
 Object Oriented (OO) Data Models since mid-90’s, to address the
limitations of traditional relational database models.
 The key feature of object-oriented databases is the power they give the
designer to specify both the structure of complex objects and the
operations that can be applied to these objects.
4
Why Object-Oriented Databases?
 Reasons for creation of Object Oriented Databases
• Need for more complex applications
• Need for additional data modeling features
• Increased use of object-oriented programming languages
 Commercial OO Database products –
• Several in the 1990’s, but did not make much impact on
mainstream data management
5
Object-Orientation Concepts
 Class
 Object
 Abstraction
 Encapsulation
 Interface
 Methods and their Signatures
 Attributes
 Object State
6
History of OO Models and Systems
 Languages:
 Simula (1960’s)
 Smalltalk (1970’s)
 C++ (late 1980’s)
 Java (1990’s and 2000’s)
7
History of OO Models and Systems
(contd.)
 Experimental Systems:
• Orion at MCC (Microelectronics and Computer
Technology Corporation) in Austin.
• IRIS at H-P labs
• Open-OODB at T.I.
• ODE at ATT Bell labs
• Postgres - Montage - Illustra at UC/B
• Encore/ObServer at Brown
8
History of OO Models and Systems
(contd.)
 Commercial OO Database products:
• Ontos
• Gemstone
• O2
• Objectivity
• Objectstore
• Versant
• Poet
• Jasmine (Fujitsu – GM)
9
 ODBMS is a database management system that implements
object-oriented data model
 The Object-oriented Database System Manifesto, Atkinson et
all, 1989. – in scientific paper described the properties which
ODBMS must satisfy:
• Object-oriented concepts
• Database management system concepts
 Implementation of object-oriented database management system
(ODBMS) is generally programmed for a specific programming language,
and differ quite with each other.
10Object-Oriented Database
Limitations of ODBMS
 No logical data independence : Modifications to the database (schema
evolution) require changes to the application and vice versa
 Lack of agreed standards, the existing standard (ODMG) is not fully
implemented
 Dependence on a single programming language. Typical OODBMS is
tied to a single programming language with it's programming interface
 Lack of interoperability with a large number of tools and features that
are used in SQL
 Lack of Ad-Hoc queries (queries on the new tables that are obtained
by joining new tables with the existing ones)
11
ODBMS in real world
 Chicago Stock Exchange - management in stocks trade (Versant)
 Radio Computing Services – automation of radio stations (POET)
 Ajou University Medical Canter in South Korea – all functions of the
hospital, including those critical such as pathology, laboratory,
blood bank, pharmacy and radiology
 CERN – big scientific data sets (Objectivity/DB)
 Federal Aviation Authority – simulation of passengers and baggage
 Electricite de France – management in electric power networks
12
13
Database Design Process
LOGICAL & PHYSICAL LAYERS 14
What is Object-Oriented Data Model?
 OO databases try to maintain a direct correspondence between
real-world and database objects so that objects do not lose their
integrity and identity and can easily be identified and operated
upon.
 Relations are not the central concept, classes and objects are the
main concept.
 Main Features:
• Powerful type system
• Classes
• Object Identity
• Inheritance
15
FEATURE 1: POWERFUL TYPE SYSTEM
 Primitive types : Integer, string, date, Boolean, float, etc.
 Structure type : Attribute can be a record with a schema,
struct { integer x, string y}
 Collection type : Attribute can be a Set, Bag, List, Array of
other types
 Reference type: Attribute can be a Pointer to another object
 OODBMS are capable of storing complex objects, I.e., objects
that are composed of other objects, and/or multi-valued
attributes.
16
FEATURE 2: CLASSES
 A ‘class’ is in replacement of ‘relation’
 Same concept as in OO programming languages
• All objects belonging to a same class share the same properties and behavior
 An ‘object’ can be thought of as ‘tuple’ (but richer content)
 An object is made of two things:
• State: attributes (name, address, birthDate of a person)
• Behavior: operations (age of a person is computed from birthDate and
current date)
 Classes encapsulate data + methods + relationships
• Unlike relations that contain data only
 In OODBMSs objects are persistent (unlike OO programming languages)
17
FEATURE 3: OBJECT IDENTITY
 OID is a unique, unchangeable object identifier generated
by the OO system regardless of its content
 Independent of the values ​​of the object attributes
 Invisible to the user
 Used for referencing objects
 Two objects are identical if they have the same identity of
the object - property that uniquely identifies them
 Even if all attributes are the same, still objects have
different OIDs
18
FEATURE 4: INHERITANCE
 A class can be defined in terms of
another one.
 Person is super-class and Student is
sub-class.
 Student class inherits attributes and
operations of Person.
19
Encapsulation
 Related to the concepts of abstract data types and information hiding in
programming languages
 The encapsulation is achieved through objects and its operations.
 Some OO models insist that all operations a user can apply to an object
must be predefined. This forces a complete encapsulation of objects.
 To encourage encapsulation, an operation is defined in two parts:
• signature or interface of the operation, specifies the operation name
and arguments (or parameters).
• method or body, specifies the implementation of the operation.
20
Encapsulation
 Operations can be invoked by passing a message to an
object, which includes the operation name and the
parameters. The object then executes the method for that
operation.
 This encapsulation permits modification of the internal
structure of an object, as well as the implementation of its
operations, without the need to disturb the external
programs that invoke these operations.
21
Polymorphism
 This refers to an operation’s ability to be applied to different types of
objects; in such a situation, an operation name may refer to several
distinct implementations, depending on the type of objects it is applied
to.
 Operator overloading: It allows the same operator name or symbol to be
bound to two or more different implementations of the operator,
depending on the type of objects to which the operator is applied
 For example + can be:
Addition in integers
Concatenation in strings (of characters)
22
Object Structure
 Every instance of an object is characterized by its state.
 Structure of an object instance is represented by a triple: (i,
c, v)
where i : object identifier
c : type constructor
v : object state or value
23
Type Constructors
 In OO databases, the state (current value) of a complex object
may be constructed from other objects (or other values) by using
certain type constructors.
 The three most basic constructors are atom, tuple and set.
 Other commonly used constructors include list, bag, and array.
 The atom constructor is used to represent all basic atomic
values, such as integers, real numbers, character strings,
Booleans, and any other basic data types that the system
supports directly.
24
Type Constructors
 The tuple type constructor is often called a structured type,
since corresponds to struct construct in C and C++. It
represents a tuple of the form <a1:i1, a2:i2,..., an:in> where aj is
attribute name and each ij is an OID.
 The set type constructor represents a set of OIDs { i1,i2,...,in},
which are the OIDs of objects of typically of same type.
 List type constructor represent the ordered list of OIDs of the
same type.
25
 Array type constructor is single dimension array of
OIDs.
 The main difference between list and array is that a
list can have an arbitrary number of element whereas
the array has a maximum size.
 The bag is similar same as set but bag has duplicate
elements.
26
Type Constructors
Object Identity, Object Structure, and
Type Constructors
 Example 1
 One possible relational database state corresponding to COMPANY
schema
27
Object Identity, Object Structure, and Type
Constructors
 Example 1 (contd.):
28
Object Identity, Object Structure, and Type
Constructors
 Example 1 (contd.)
29
Object Identity, Object Structure, and Type
Constructors
 Example 1 (contd.)
We use i1, i2, i3, . . . to stand for unique system-generated object
identifiers. Consider the following objects:
 o1 = (i1, atom, ‘Houston’)
 o2 = (i2, atom, ‘Bellaire’)
 o3 = (i3, atom, ‘Sugarland’)
 o4 = (i4, atom, 5)
 o5 = (i5, atom, ‘Research’)
 o6 = (i6, atom, ‘1988-05-22’)
 o7 = (i7, set, {i1, i2, i3})
30
Object Identity, Object Structure, and
Type Constructors
 Example 1(contd.)
 o8 = (i8, tuple, <dname:i5, dnumber:i4, mgr:i9, locations:i7,
employees:i10, projects:i11>)
 o9 = (i9, tuple, <manager:i12, manager_start_date:i6>)
 o10 = (i10, set, {i12, i13, i14})
 o11 = (i11, set {i15, i16, i17})
 o12 = (i12, tuple, <fname:i18, minit:i19, lname:i20, ssn:i21, . . ., salary:i26,
supervisor:i27, dept:i8>)
 . . .
31
Object Identity, Object Structure, and
Type Constructors
 Example 1 (contd.)
 The first six objects listed in this example represent atomic
values.
 Object seven is a set-valued object that represents the set
of locations for department 5; the set refers to the atomic
objects with values {‘Houston’, ‘Bellaire’, ‘Sugarland’}.
 Object 8 is a tuple-valued object that represents
department 5 itself, and has the attributes DNAME,
DNUMBER, MGR, LOCATIONS, and so on.
32
Object Identity, Object Structure, and
Type Constructors
 Example 2:
 This example illustrates the difference between the two
definitions for comparing object states for equality.
 o1 = (i1, tuple, <a1:i4, a2:i6>)
 o2 = (i2, tuple, <a1:i5, a2:i6>)
 o3 = (i3, tuple, <a1:i4, a2:i6>)
 o4 = (i4, atom, 10)
 o5 = (i5, atom, 10)
 o6 = (i6, atom, 20)
33
Object Identity, Object Structure, and Type
Constructors
 Example 2 (contd.):
 In this example, The objects o1 and o2 have equal states,
since their states at the atomic level are the same but the
values are reached through distinct objects o4 and o5.
 However, the states of objects o1 and o3 are identical,
even though the objects themselves are not because they
have distinct OIDs.
 Similarly, although the states of o4 and o5 are identical,
the actual objects o4 and o5 are equal but not identical,
because they have distinct OIDs.
34
Object Identity,
Object Structure,
and Type
Constructors
35
Figure
Representation of a
DEPARTMENT complex
object as a graph
Object Structure and Type Constructors
36
Specifying Object Behavior via Class
Operations
The main idea is to define the behavior of a type of
object based on the operations that can be externally
applied to objects of that type.
In general, the implementation of an operation can be
specified in a general-purpose programming language
that provides flexibility and power in defining the
operations.
37
Specifying Object Behavior via Class
Operations (contd.):
 For database applications, the requirement that all objects be
completely encapsulated is too stringent.
 One way of relaxing this requirement is to divide the structure of
an object into visible and hidden attributes (instance variables).
 The visible attributes may be directly accessed for reading by
external operators of by high level query language.
 The hidden attributes of an object are completely encapsulated
and can be accessed only through predefined operations.
38
Encapsulation of
Operations
39
Persistence of Objects
 Persistent objects are the objects that are created and stored in
database and exist even after the program termination.
 Typical mechanisms for making an object persistence are:
Naming and Reachability.
• Naming Mechanism: Assign an object a unique persistent
name through which it can be retrieved by this and other
programs.
• Reachability Mechanism: Make the object reachable from
some persistent object. An object B is said to be reachable
from an object A if a sequence of references in the object
graph lead from object A to object B.
40
Inheritance
 Type (class) Hierarchy
• A type in its simplest form can be defined by giving it a type
name and then listing the names of its visible (public) functions
• When specifying a type in this section, we use the following
format, which does not specify arguments of functions, to
simplify the discussion:
• TYPE_NAME: function, function, . . . , function
• Example:
PERSON: Name, Address, Birthdate, Age, SSN
41
Inheritance
 Subtype:
When the designer or user must create a new type that is
similar but not identical to an already defined type Supertype.
Subtype inherits all the functions of the Supertype.
Example: 1
• PERSON: Name, Address, Birthdate, Age, SSN
• EMPLOYEE subtype-of PERSON: Salary, HireDate, Seniority
• STUDENT subtype-of PERSON: Major, GPA
42
Inheritance: Example (2)
 Consider a type that describes objects in plane geometry, which may
be defined as follows:
• GEOMETRY_OBJECT: Shape, Area, ReferencePoint
 Now suppose that we want to define a number of subtypes for the
GEOMETRY_OBJECT type, as follows:
• RECTANGLE subtype-of GEOMETRY_OBJECT: Width, Height
• TRIANGLE subtype-of GEOMETRY_OBJECT: Side1, Side2, Angle
• CIRCLE subtype-of GEOMETRY_OBJECT: Radius
43
Inheritance: Example (2) (contd.)
 An alternative way of declaring these three subtypes is to specify
the value of the Shape attribute as a condition that must be
satisfied for objects of each subtype:
• RECTANGLE subtype-of GEOMETRY_OBJECT (Shape=‘rectangle’):
Width, Height
• TRIANGLE subtype-of GEOMETRY_OBJECT (Shape=‘triangle’): Side1,
Side2, Angle
• CIRCLE subtype-of GEOMETRY_OBJECT (Shape=‘circle’): Radius
44
Inheritance
 Multiple Inheritance and Selective Inheritance
Multiple inheritance in a type hierarchy occurs when a
certain subtype T is a subtype of two (or more) types and
hence inherits the functions (attributes and methods) of
both supertypes.
For example, we may create a subtype
ENGINEERING_MANAGER that is a subtype of both
MANAGER and ENGINEER.
This leads to the creation of a type lattice rather than a type
hierarchy.
45
Extents
 Extents:
 The collection of objects of the same type in the database is known as
an extent of the type.
 Extent is the current set of objects belonging to the class.
 Queries in OQL refer to the extent of a class and not the class directly.
 Persistent Collection:
 This holds a collection of objects that is stored permanently in the
database and hence can be accessed and shared by multiple
programs
 Transient Collection:
 This exists temporarily during the execution of a program but is not kept
when the program terminates
46
Complex Objects
Unstructured complex object:
 These is provided by a DBMS and permits the storage and retrieval
of large objects that are needed by the database application.
 Typical examples of such objects are bitmap images and long
text strings (such as documents); they are also known as binary
large objects, or BLOBs for short.
 This has been the standard way by which Relational DBMSs
have dealt with supporting complex objects, leaving the
operations on those objects outside the RDBMS.
47
Complex Objects
 Structured complex object:
 This differs from an unstructured complex object in that the object’s
structure is defined by repeated application of the type constructors
provided by the OODBMS.
 Hence, the object structure is defined and known to the OODBMS.
 The OODBMS also defines methods or operations on it.
 For example: The DEPARTMENT object is structured object.
48
define type DEPARTMENT
tuple ( Dname: string;
Dnumber: integer;
Mgr: tuple ( Manager: EMPLOYEE;
Start_date: DATE; );
Locations: set(string);
Employees: set(EMPLOYEE);
Projects: set(PROJECT); );
Versions and Configurations
 Versions
• Some OO systems provide capabilities for dealing with multiple
versions of the same object (a feature that is essential in design and
engineering applications).
• For example, an old version of an object that represents a tested
and verified design should be retained until the new version is tested
and verified: very crucial for designs in manufacturing process
control, architecture , software systems …..
 Configuration:
• A configuration of the complex object is a collection consisting of
one version of each module arranged in such a way that the module
versions in the configuration are compatible and together form a
valid version of the complex object.
49
Current Status
 OODB market growing very slowly these days.
 O-O ideas are being used in a large number of applications, without
explicitly using the OODB platform to store data.
 Growth:
 O-O tools for modeling and analysis, O-O Programming
Languages like Java and C++
 Compromise Solution Proposed:
 Object Relational DB Management (Informix Universal Server,
Oracle 11g, IBM’s UDB, DB2/II …)
50
Exercise
51
1. What is OID? How persistent objects are maintained in OO Database?
2. Define state of an object. Distinguish between persistent and transient
objects.
3. Distinguish multiple inheritance and selective inheritance in OO
concepts.
4. What is the difference between structured and unstructured complex
object? Differentiate identical versus equal objects with examples.
5. What are the advantages and disadvantages of OODBMS?
THANK YOU !
52

More Related Content

PPTX
Object oriented database concepts
PPT
Oodbms ch 20
PPTX
PPT
Anatomy of classic map reduce in hadoop
PPTX
Encapsulation of operations, methods & persistence
PPTX
DISTRIBUTED DATABASE WITH RECOVERY TECHNIQUES
PPTX
Data mining primitives
PPTX
Object Relational Database Management System(ORDBMS)
Object oriented database concepts
Oodbms ch 20
Anatomy of classic map reduce in hadoop
Encapsulation of operations, methods & persistence
DISTRIBUTED DATABASE WITH RECOVERY TECHNIQUES
Data mining primitives
Object Relational Database Management System(ORDBMS)

What's hot (20)

PPTX
Transaction management DBMS
PPTX
Distributed concurrency control
PPTX
Object database standards, languages and design
PPTX
Concurrency control
PPT
Object oriented analysis
PPTX
Validation based protocol
PPTX
Conceptual design & ER Model.pptx
PPTX
Temporal databases
PPTX
Recovery techniques
PDF
Normalization in DBMS
PDF
Object oriented databases
PPTX
And or graph
PPTX
IoT System Management.pptx
PPTX
Object relational database management system
PPTX
Distributed database management system
PDF
Presentation On NoSQL Databases
PPTX
Concurrency control
PPTX
Chapter-7 Relational Calculus
PPT
Query processing-and-optimization
Transaction management DBMS
Distributed concurrency control
Object database standards, languages and design
Concurrency control
Object oriented analysis
Validation based protocol
Conceptual design & ER Model.pptx
Temporal databases
Recovery techniques
Normalization in DBMS
Object oriented databases
And or graph
IoT System Management.pptx
Object relational database management system
Distributed database management system
Presentation On NoSQL Databases
Concurrency control
Chapter-7 Relational Calculus
Query processing-and-optimization
Ad

Similar to Odbms concepts (20)

PPT
Chapter 1 - Concepts for Object Databases.ppt
PPTX
ADBS sy Chapter One for computer sciences
PPTX
MIT302 Lesson 2_Advanced Database Systems.pptx
PPTX
Concepts for Object Oriented Databases.ppt
PDF
OODBMS Concepts - National University of Singapore.pdf
PDF
Chapter – 2 Data Models.pdf
PDF
Advanced DBMS- Unit 1.pdf Advanced DBMS dives into complex data management fo...
PPTX
Object oriented modeling
PPT
Overview of Object-Oriented Concepts Characteristics by vikas jagtap
PPTX
Introduction to Object Oriented databases
PPT
CHapter 01 one data base management system.ppt
PDF
Object-Oriented Database Model For Effective Mining Of Advanced Engineering M...
PPT
Introduction to odbms
PPTX
ADBMS Object and Object Relational Databases
PPTX
OOSD Lecture 1-1.pptx FOR ENGINEERING STUDENTS
DOCX
Getting Started with Entity Framework in .NET
PDF
Comparision
PDF
Data Management Evolution of the data management systems
PPTX
OODP Unit 1 OOPs classes and objects
PPTX
Lect 3 Object Oriented Model.pptx from m
Chapter 1 - Concepts for Object Databases.ppt
ADBS sy Chapter One for computer sciences
MIT302 Lesson 2_Advanced Database Systems.pptx
Concepts for Object Oriented Databases.ppt
OODBMS Concepts - National University of Singapore.pdf
Chapter – 2 Data Models.pdf
Advanced DBMS- Unit 1.pdf Advanced DBMS dives into complex data management fo...
Object oriented modeling
Overview of Object-Oriented Concepts Characteristics by vikas jagtap
Introduction to Object Oriented databases
CHapter 01 one data base management system.ppt
Object-Oriented Database Model For Effective Mining Of Advanced Engineering M...
Introduction to odbms
ADBMS Object and Object Relational Databases
OOSD Lecture 1-1.pptx FOR ENGINEERING STUDENTS
Getting Started with Entity Framework in .NET
Comparision
Data Management Evolution of the data management systems
OODP Unit 1 OOPs classes and objects
Lect 3 Object Oriented Model.pptx from m
Ad

More from Dabbal Singh Mahara (18)

PPTX
Spatial databases
PPTX
Normalization
PPTX
Mobile databases
PPTX
Active database
PPTX
Deductive databases
PPTX
Relational model
PPTX
Overview of dbms
PPTX
ER modeling
PPTX
EER modeling
PPTX
Unit 9 graph
PPTX
Unit 7 sorting
PPTX
Unit 6 tree
PPTX
Unit 5 linked list
PPTX
Unit 4 queue
PPTX
Unit 8 searching and hashing
PPTX
Unit 3 stack
PPTX
Unit 2 algorithm
Spatial databases
Normalization
Mobile databases
Active database
Deductive databases
Relational model
Overview of dbms
ER modeling
EER modeling
Unit 9 graph
Unit 7 sorting
Unit 6 tree
Unit 5 linked list
Unit 4 queue
Unit 8 searching and hashing
Unit 3 stack
Unit 2 algorithm

Recently uploaded (20)

PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
composite construction of structures.pdf
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PPT
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
CYBER-CRIMES AND SECURITY A guide to understanding
PDF
Well-logging-methods_new................
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PPTX
Construction Project Organization Group 2.pptx
Embodied AI: Ushering in the Next Era of Intelligent Systems
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
composite construction of structures.pdf
Foundation to blockchain - A guide to Blockchain Tech
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
CYBER-CRIMES AND SECURITY A guide to understanding
Well-logging-methods_new................
UNIT 4 Total Quality Management .pptx
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
Model Code of Practice - Construction Work - 21102022 .pdf
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
Construction Project Organization Group 2.pptx

Odbms concepts

  • 2. Traditional Data Models  Traditional Data Models: • Hierarchical • Network (since mid-60’s) • Relational (since 1970 and commercially since 1982)  These traditional models have been quite successful in developing the database technology required for many traditional business database applications. 2
  • 3. RELATIONAL MODEL  Relations are the key concept, everything else is around relations  Primitive data types, e.g., strings, integer, date, etc.  Great normalization, query optimization, and theory  What is missing? • Handling of complex objects • Handling of complex data types • Code is not coupled with data • No inheritance, encapsulation, etc. 3
  • 4. Object-Oriented Database  Relational model has certain limitations when more complex database applications must be designed and implemented, like CAD/CAM, CIM, scientific experiments, telecommunications, GIS, and multimedia.  Object Oriented (OO) Data Models since mid-90’s, to address the limitations of traditional relational database models.  The key feature of object-oriented databases is the power they give the designer to specify both the structure of complex objects and the operations that can be applied to these objects. 4
  • 5. Why Object-Oriented Databases?  Reasons for creation of Object Oriented Databases • Need for more complex applications • Need for additional data modeling features • Increased use of object-oriented programming languages  Commercial OO Database products – • Several in the 1990’s, but did not make much impact on mainstream data management 5
  • 6. Object-Orientation Concepts  Class  Object  Abstraction  Encapsulation  Interface  Methods and their Signatures  Attributes  Object State 6
  • 7. History of OO Models and Systems  Languages:  Simula (1960’s)  Smalltalk (1970’s)  C++ (late 1980’s)  Java (1990’s and 2000’s) 7
  • 8. History of OO Models and Systems (contd.)  Experimental Systems: • Orion at MCC (Microelectronics and Computer Technology Corporation) in Austin. • IRIS at H-P labs • Open-OODB at T.I. • ODE at ATT Bell labs • Postgres - Montage - Illustra at UC/B • Encore/ObServer at Brown 8
  • 9. History of OO Models and Systems (contd.)  Commercial OO Database products: • Ontos • Gemstone • O2 • Objectivity • Objectstore • Versant • Poet • Jasmine (Fujitsu – GM) 9
  • 10.  ODBMS is a database management system that implements object-oriented data model  The Object-oriented Database System Manifesto, Atkinson et all, 1989. – in scientific paper described the properties which ODBMS must satisfy: • Object-oriented concepts • Database management system concepts  Implementation of object-oriented database management system (ODBMS) is generally programmed for a specific programming language, and differ quite with each other. 10Object-Oriented Database
  • 11. Limitations of ODBMS  No logical data independence : Modifications to the database (schema evolution) require changes to the application and vice versa  Lack of agreed standards, the existing standard (ODMG) is not fully implemented  Dependence on a single programming language. Typical OODBMS is tied to a single programming language with it's programming interface  Lack of interoperability with a large number of tools and features that are used in SQL  Lack of Ad-Hoc queries (queries on the new tables that are obtained by joining new tables with the existing ones) 11
  • 12. ODBMS in real world  Chicago Stock Exchange - management in stocks trade (Versant)  Radio Computing Services – automation of radio stations (POET)  Ajou University Medical Canter in South Korea – all functions of the hospital, including those critical such as pathology, laboratory, blood bank, pharmacy and radiology  CERN – big scientific data sets (Objectivity/DB)  Federal Aviation Authority – simulation of passengers and baggage  Electricite de France – management in electric power networks 12
  • 14. LOGICAL & PHYSICAL LAYERS 14
  • 15. What is Object-Oriented Data Model?  OO databases try to maintain a direct correspondence between real-world and database objects so that objects do not lose their integrity and identity and can easily be identified and operated upon.  Relations are not the central concept, classes and objects are the main concept.  Main Features: • Powerful type system • Classes • Object Identity • Inheritance 15
  • 16. FEATURE 1: POWERFUL TYPE SYSTEM  Primitive types : Integer, string, date, Boolean, float, etc.  Structure type : Attribute can be a record with a schema, struct { integer x, string y}  Collection type : Attribute can be a Set, Bag, List, Array of other types  Reference type: Attribute can be a Pointer to another object  OODBMS are capable of storing complex objects, I.e., objects that are composed of other objects, and/or multi-valued attributes. 16
  • 17. FEATURE 2: CLASSES  A ‘class’ is in replacement of ‘relation’  Same concept as in OO programming languages • All objects belonging to a same class share the same properties and behavior  An ‘object’ can be thought of as ‘tuple’ (but richer content)  An object is made of two things: • State: attributes (name, address, birthDate of a person) • Behavior: operations (age of a person is computed from birthDate and current date)  Classes encapsulate data + methods + relationships • Unlike relations that contain data only  In OODBMSs objects are persistent (unlike OO programming languages) 17
  • 18. FEATURE 3: OBJECT IDENTITY  OID is a unique, unchangeable object identifier generated by the OO system regardless of its content  Independent of the values ​​of the object attributes  Invisible to the user  Used for referencing objects  Two objects are identical if they have the same identity of the object - property that uniquely identifies them  Even if all attributes are the same, still objects have different OIDs 18
  • 19. FEATURE 4: INHERITANCE  A class can be defined in terms of another one.  Person is super-class and Student is sub-class.  Student class inherits attributes and operations of Person. 19
  • 20. Encapsulation  Related to the concepts of abstract data types and information hiding in programming languages  The encapsulation is achieved through objects and its operations.  Some OO models insist that all operations a user can apply to an object must be predefined. This forces a complete encapsulation of objects.  To encourage encapsulation, an operation is defined in two parts: • signature or interface of the operation, specifies the operation name and arguments (or parameters). • method or body, specifies the implementation of the operation. 20
  • 21. Encapsulation  Operations can be invoked by passing a message to an object, which includes the operation name and the parameters. The object then executes the method for that operation.  This encapsulation permits modification of the internal structure of an object, as well as the implementation of its operations, without the need to disturb the external programs that invoke these operations. 21
  • 22. Polymorphism  This refers to an operation’s ability to be applied to different types of objects; in such a situation, an operation name may refer to several distinct implementations, depending on the type of objects it is applied to.  Operator overloading: It allows the same operator name or symbol to be bound to two or more different implementations of the operator, depending on the type of objects to which the operator is applied  For example + can be: Addition in integers Concatenation in strings (of characters) 22
  • 23. Object Structure  Every instance of an object is characterized by its state.  Structure of an object instance is represented by a triple: (i, c, v) where i : object identifier c : type constructor v : object state or value 23
  • 24. Type Constructors  In OO databases, the state (current value) of a complex object may be constructed from other objects (or other values) by using certain type constructors.  The three most basic constructors are atom, tuple and set.  Other commonly used constructors include list, bag, and array.  The atom constructor is used to represent all basic atomic values, such as integers, real numbers, character strings, Booleans, and any other basic data types that the system supports directly. 24
  • 25. Type Constructors  The tuple type constructor is often called a structured type, since corresponds to struct construct in C and C++. It represents a tuple of the form <a1:i1, a2:i2,..., an:in> where aj is attribute name and each ij is an OID.  The set type constructor represents a set of OIDs { i1,i2,...,in}, which are the OIDs of objects of typically of same type.  List type constructor represent the ordered list of OIDs of the same type. 25
  • 26.  Array type constructor is single dimension array of OIDs.  The main difference between list and array is that a list can have an arbitrary number of element whereas the array has a maximum size.  The bag is similar same as set but bag has duplicate elements. 26 Type Constructors
  • 27. Object Identity, Object Structure, and Type Constructors  Example 1  One possible relational database state corresponding to COMPANY schema 27
  • 28. Object Identity, Object Structure, and Type Constructors  Example 1 (contd.): 28
  • 29. Object Identity, Object Structure, and Type Constructors  Example 1 (contd.) 29
  • 30. Object Identity, Object Structure, and Type Constructors  Example 1 (contd.) We use i1, i2, i3, . . . to stand for unique system-generated object identifiers. Consider the following objects:  o1 = (i1, atom, ‘Houston’)  o2 = (i2, atom, ‘Bellaire’)  o3 = (i3, atom, ‘Sugarland’)  o4 = (i4, atom, 5)  o5 = (i5, atom, ‘Research’)  o6 = (i6, atom, ‘1988-05-22’)  o7 = (i7, set, {i1, i2, i3}) 30
  • 31. Object Identity, Object Structure, and Type Constructors  Example 1(contd.)  o8 = (i8, tuple, <dname:i5, dnumber:i4, mgr:i9, locations:i7, employees:i10, projects:i11>)  o9 = (i9, tuple, <manager:i12, manager_start_date:i6>)  o10 = (i10, set, {i12, i13, i14})  o11 = (i11, set {i15, i16, i17})  o12 = (i12, tuple, <fname:i18, minit:i19, lname:i20, ssn:i21, . . ., salary:i26, supervisor:i27, dept:i8>)  . . . 31
  • 32. Object Identity, Object Structure, and Type Constructors  Example 1 (contd.)  The first six objects listed in this example represent atomic values.  Object seven is a set-valued object that represents the set of locations for department 5; the set refers to the atomic objects with values {‘Houston’, ‘Bellaire’, ‘Sugarland’}.  Object 8 is a tuple-valued object that represents department 5 itself, and has the attributes DNAME, DNUMBER, MGR, LOCATIONS, and so on. 32
  • 33. Object Identity, Object Structure, and Type Constructors  Example 2:  This example illustrates the difference between the two definitions for comparing object states for equality.  o1 = (i1, tuple, <a1:i4, a2:i6>)  o2 = (i2, tuple, <a1:i5, a2:i6>)  o3 = (i3, tuple, <a1:i4, a2:i6>)  o4 = (i4, atom, 10)  o5 = (i5, atom, 10)  o6 = (i6, atom, 20) 33
  • 34. Object Identity, Object Structure, and Type Constructors  Example 2 (contd.):  In this example, The objects o1 and o2 have equal states, since their states at the atomic level are the same but the values are reached through distinct objects o4 and o5.  However, the states of objects o1 and o3 are identical, even though the objects themselves are not because they have distinct OIDs.  Similarly, although the states of o4 and o5 are identical, the actual objects o4 and o5 are equal but not identical, because they have distinct OIDs. 34
  • 35. Object Identity, Object Structure, and Type Constructors 35 Figure Representation of a DEPARTMENT complex object as a graph
  • 36. Object Structure and Type Constructors 36
  • 37. Specifying Object Behavior via Class Operations The main idea is to define the behavior of a type of object based on the operations that can be externally applied to objects of that type. In general, the implementation of an operation can be specified in a general-purpose programming language that provides flexibility and power in defining the operations. 37
  • 38. Specifying Object Behavior via Class Operations (contd.):  For database applications, the requirement that all objects be completely encapsulated is too stringent.  One way of relaxing this requirement is to divide the structure of an object into visible and hidden attributes (instance variables).  The visible attributes may be directly accessed for reading by external operators of by high level query language.  The hidden attributes of an object are completely encapsulated and can be accessed only through predefined operations. 38
  • 40. Persistence of Objects  Persistent objects are the objects that are created and stored in database and exist even after the program termination.  Typical mechanisms for making an object persistence are: Naming and Reachability. • Naming Mechanism: Assign an object a unique persistent name through which it can be retrieved by this and other programs. • Reachability Mechanism: Make the object reachable from some persistent object. An object B is said to be reachable from an object A if a sequence of references in the object graph lead from object A to object B. 40
  • 41. Inheritance  Type (class) Hierarchy • A type in its simplest form can be defined by giving it a type name and then listing the names of its visible (public) functions • When specifying a type in this section, we use the following format, which does not specify arguments of functions, to simplify the discussion: • TYPE_NAME: function, function, . . . , function • Example: PERSON: Name, Address, Birthdate, Age, SSN 41
  • 42. Inheritance  Subtype: When the designer or user must create a new type that is similar but not identical to an already defined type Supertype. Subtype inherits all the functions of the Supertype. Example: 1 • PERSON: Name, Address, Birthdate, Age, SSN • EMPLOYEE subtype-of PERSON: Salary, HireDate, Seniority • STUDENT subtype-of PERSON: Major, GPA 42
  • 43. Inheritance: Example (2)  Consider a type that describes objects in plane geometry, which may be defined as follows: • GEOMETRY_OBJECT: Shape, Area, ReferencePoint  Now suppose that we want to define a number of subtypes for the GEOMETRY_OBJECT type, as follows: • RECTANGLE subtype-of GEOMETRY_OBJECT: Width, Height • TRIANGLE subtype-of GEOMETRY_OBJECT: Side1, Side2, Angle • CIRCLE subtype-of GEOMETRY_OBJECT: Radius 43
  • 44. Inheritance: Example (2) (contd.)  An alternative way of declaring these three subtypes is to specify the value of the Shape attribute as a condition that must be satisfied for objects of each subtype: • RECTANGLE subtype-of GEOMETRY_OBJECT (Shape=‘rectangle’): Width, Height • TRIANGLE subtype-of GEOMETRY_OBJECT (Shape=‘triangle’): Side1, Side2, Angle • CIRCLE subtype-of GEOMETRY_OBJECT (Shape=‘circle’): Radius 44
  • 45. Inheritance  Multiple Inheritance and Selective Inheritance Multiple inheritance in a type hierarchy occurs when a certain subtype T is a subtype of two (or more) types and hence inherits the functions (attributes and methods) of both supertypes. For example, we may create a subtype ENGINEERING_MANAGER that is a subtype of both MANAGER and ENGINEER. This leads to the creation of a type lattice rather than a type hierarchy. 45
  • 46. Extents  Extents:  The collection of objects of the same type in the database is known as an extent of the type.  Extent is the current set of objects belonging to the class.  Queries in OQL refer to the extent of a class and not the class directly.  Persistent Collection:  This holds a collection of objects that is stored permanently in the database and hence can be accessed and shared by multiple programs  Transient Collection:  This exists temporarily during the execution of a program but is not kept when the program terminates 46
  • 47. Complex Objects Unstructured complex object:  These is provided by a DBMS and permits the storage and retrieval of large objects that are needed by the database application.  Typical examples of such objects are bitmap images and long text strings (such as documents); they are also known as binary large objects, or BLOBs for short.  This has been the standard way by which Relational DBMSs have dealt with supporting complex objects, leaving the operations on those objects outside the RDBMS. 47
  • 48. Complex Objects  Structured complex object:  This differs from an unstructured complex object in that the object’s structure is defined by repeated application of the type constructors provided by the OODBMS.  Hence, the object structure is defined and known to the OODBMS.  The OODBMS also defines methods or operations on it.  For example: The DEPARTMENT object is structured object. 48 define type DEPARTMENT tuple ( Dname: string; Dnumber: integer; Mgr: tuple ( Manager: EMPLOYEE; Start_date: DATE; ); Locations: set(string); Employees: set(EMPLOYEE); Projects: set(PROJECT); );
  • 49. Versions and Configurations  Versions • Some OO systems provide capabilities for dealing with multiple versions of the same object (a feature that is essential in design and engineering applications). • For example, an old version of an object that represents a tested and verified design should be retained until the new version is tested and verified: very crucial for designs in manufacturing process control, architecture , software systems …..  Configuration: • A configuration of the complex object is a collection consisting of one version of each module arranged in such a way that the module versions in the configuration are compatible and together form a valid version of the complex object. 49
  • 50. Current Status  OODB market growing very slowly these days.  O-O ideas are being used in a large number of applications, without explicitly using the OODB platform to store data.  Growth:  O-O tools for modeling and analysis, O-O Programming Languages like Java and C++  Compromise Solution Proposed:  Object Relational DB Management (Informix Universal Server, Oracle 11g, IBM’s UDB, DB2/II …) 50
  • 51. Exercise 51 1. What is OID? How persistent objects are maintained in OO Database? 2. Define state of an object. Distinguish between persistent and transient objects. 3. Distinguish multiple inheritance and selective inheritance in OO concepts. 4. What is the difference between structured and unstructured complex object? Differentiate identical versus equal objects with examples. 5. What are the advantages and disadvantages of OODBMS?

Editor's Notes

  • #5: These newer applications have requirements and characteristics that differ from those of traditional business applications, such as more complex structures for objects, longer-duration transactions, new data types for storing images or large textual items and need to define nonstandard application-specific operations. The object oriented database applications were proposed to meet the needs of these more complex applications. The object-oriented approach offers the flexibility to handle some of these requirements without being limited by the data types and query languages available in traditional systems. OODBMS are capable of storing complex objects, I.e., objects that are composed of other objects, and/or multi-valued attributes.
  • #6: The increasing use of object oriented programming languages in developing software applications, promoted the use of object oriented database systems. This is because databases are the fundamental components in any software systems, and traditional databases are difficult to use with Object-Oriented software applications that are developed in an OOP language. The object oriented databases are designed so they can be directly-seamlessly- integrated with software that is developed using object-oriented programming languages. The additional data modelling features such as: ENCAPSULATION OR OBJECTS, INHERITANCE, COMPLEX DATA TYPES, POLYMORPHISM, BEHAVIORS are not the part of traditional databases, so provided by ODBMS.
  • #9: MCC – Microelectronics and Computer Technology Corporation, Austin, Texas H-P labs – Hewlett Packard Laboratories T.I. – Texas Instruments AT & T Bell Labs – American Telephone and Telegraph Bell Labs Brown – Brown University
  • #10: Ontos - DB of Ontos Objectivity - DB of Objectivity Inc. Gemstone – Server of GeSstone Systems Versant - Versant Corporation