Overview RDBMS-ORDBMS- OODBMS

advertisement
Overview RDBMS-ORDBMSOODBMS
1
Database Models – Transition
Hierarchical Data Model
Network Data Model
Relational Data Model
ER Data Model
Semantic Data Model
Object-Relational DM
Object-Oriented DM
2
Main Issues
ƒ Relational DBMS Limitations
ƒ What is an OODBMS?
ƒ Advantages and Disadvantages of OODBMS
ƒ What is an ORDBMS?
ƒ What is SQL3?
ƒ Comparison of OODBMS and ORDBMS
ƒ When to use an OODBMS
ƒ When to use an ORDBMS
3
Relational DBMS Limitations
ƒ
Semantic overloading.
ƒ Poor representation of ‘real world’ entities
ƒ Poor support for integrity & business constraints.
ƒ Homogeneous data structure.
ƒ Limited operations.
ƒ Difficulty handling recursive queries.
ƒ Difficulty with ‘Long Transactions’.
4
Relational DBMS Limitations
ƒ
Normalisation (Normal Forms and FDs) sometimes lead to
relations which do not exist, or correspond, to entities in the
real world. This compounds on the ‘join’ feature of query
processing
ƒ
The many to many relationship is difficult to express.
ƒ
The RDBMS has domains, keys, multi-valued and join
dependencies
5
OODBMS Architecture
OBJECT ORIENTED DATABASE MANAGEMENT SYSTEM
OOPL
DBMS
ƒComplex Objects
ƒObject Identity
ƒMethods & Messages
ƒInheritance
ƒPolymorphism
ƒExtensibility
ƒComputational Completeness
Persistence
Disc Management
Data Sharing
Reliability
Security
Ad Hoc Querying
6
OODBMS Main Features
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
ƒ
Complex objects
Object Identity
Encapsulation
Classes
Inheritance
Overriding and late-binding
Extensibility
Computational completeness
Persistence
Concurrency
Recovery
Ad-hoc querying
7
Storage-Levels
RDBMS Storage
Main or virtual
memory
ODBMS Storage
Main or virtual
memory
Transforming and
type checking
SQL
Secondary
storage
Secondary
storage
8
OODBMS Advantages
ƒ Enriched modelling capabilities
ƒ Extensibility
ƒ Support for schema evolution.
ƒ Applicable for advanced database applications
ƒ Improved performance.
9
OODBMS Disadvantages
ƒ
Lack of a universal data model ?
ƒ Ad-hoc querying compromises encapsulation.
ƒ Locking at object-level impacts performance
ƒ Complexity
ƒ Lack of support for views
ƒ Lack of support for security
10
Then What is an ORDBMS ?
ƒAn Object-Relational database adds features associated with objectoriented systems to a RDBMS
OR
ƒExtend the relational data model by including object orientation
and constructs to deal with added data types
11
Object-Relational DBMS Features
OODBS support noted by RDBMS vendors include
ƒ User-extensible type system
ƒ Encapsulation
ƒ Inheritance
ƒ Polymorphism
ƒ Dynamic binding of methods
ƒ Complex objects including first normal form objects
ƒ Object Identity
12
ORDBMS Drawbacks
Disadvantages of ORDBMS
ƒ Complexity
ƒ Increased costs
ƒ Unclear if the ORDBMS will actually combine
relationships and encapsulated objects to correctly and
completely mirror the ‘real world
ƒ Provision of a language(s) which will front end to SQL
and will provide a migration path for existing SQL
users
13
ORDBMS-SQL3
SQL3 is a superset of SQL/92, in that it supports all of the
constructs supported by that standard, as well as adding new
ones of its own.
New Types
ƒ Extended Base Types.
ƒ Row Types.
ƒ User-Defined Types.
ƒ User-Defined Routines.
ƒ Sub-Types and Super-Types.
ƒ Sub-Tables and Super-Tables.
ƒ Reference Types and Object Identity.
ƒ Collection Types.
14
OODBMS or ORDBMS ?
ƒOODBMS put more emphasis on the role of the client side
This can improve long, process intensive, transactions.
ƒORDBMS SQL is still the language for data definition,
manipulation and query
ƒOODBMS have been optimised to directly support objectoriented applications and specific OO languages
ƒORDBMS are supported by most of the ‘database vendors’
in the DBMS market place
15
OODBMS or ORDBMS ?
ƒORDBMS Most third-party database tools are written for
the relational model and will therefore be compatible with
SQL3
ƒORDBMS search, access and manipulate complex data types
in the database with standard (SQL3 ?), without breaking the
rules of the relational data model
ƒOODBMS The ODMG standard group’s OQL is now the
standard query language amongst OODBMS vendors
16
OODBMS or ORDBMS ?
When to use an ODBMS?
ƒIn applications that generally retrieve relatively few
(generally physically large) highly complex objects and
work on them for long periods of time.
When to use an ORDBMS?
ƒIn applications that process a large number of shortlived (generally ad-hoc query) transactions on data
items that can be complex in structure
17
Concluding Remarks
ƒ OODBMS:
Abandon SQL (use an OO language instead)
ƒ ORDBMS:
Extend SQL (with OO features)
18
Concluding Remarks
ƒObject-oriented capabilities have in effect turned the relational
model and the process of normalization on its head.
ƒVarious nested objects and/ or references can be queried without
doing a join.
ƒA shift from the relational to the object-oriented model is taking
place ?
19
Download