Académique Documents
Professionnel Documents
Culture Documents
Database Evolution
What is an OODBMS?
Database incorporating object-oriented programming features.
Most significant characteristic
Combining object-oriented programming technology with database for an integrated application development system.
Object-oriented system
Consistency with OO programming languages. Complex objects Object identity Encapsulation Classes or types Inheritance Overriding with late binding Extensibility Computational completeness
5
DBMS Requirements
Persistence
Ability of data to survive execution of processes for reuse
Concurrency
Accommodate multiple simultaneous users of database.
Recovery
Coherently recover data from hardware or software failures.
OO Requirements 1 - 4
Complex objects
Not easily identified; typically in many-to-many relationships.
Object identity
Objects exist independent of their value.
Encapsulation
distinguish between object implementation and interface.
Classes or types
Set of objects with common attributes.
OO Requirements 5 - 6
Inheritance
Common attributes and operations inherited from parent class
4 types: substitution, inclusion, constraint, specialization.
OO Requirements 7 8
Extensibility
A method exists to define new object types. No distinction in usage between systemdefined types and user-defined types.
Computational completeness
Any computable function can be expressed using the DML of the database system.
9
Design transactions
Support for transaction model of business databases.
Versions
Most new applications involve design activities requiring versioning.
11
Representation system
Types available of representing objects in system.
Type system
Formation of types.
Uniformity
Storage of types, objects, methods. User view of type, objects, and methods.
12
13
Higher performance, lower development costs. Somewhat limited handling of complex data.
Object-Relational DBMSs
Combines both Relational DBMS and Object-Oriented DBMS.
Stores both objects and tuples in DBMS. Advantages and disadvantages of both systems.
15
16
17
18
19
Evolution of OODBMS
21
22
23
Persistence
Objects created may have different lifetimes:
transient: allocated memory managed by the programming language runtime system.
E.g., local variables in procedures have a lifetime of a procedure execution global variables have a lifetime of a program execution
Classes are declared to be persistence-capable or transient. Different languages have different mechanisms to make objects persistent:
creation time: Object declared persistent at creation time (e.g., in C++ binding) (class must be persistent-capable) persistence by reachability: object is persistent if it can be reached from a persistent object (e.g., in Java binding) (class must be persistentcapable).
24
Programmer does not need to write explicit code to fetch data to and from database
persistent objects to programmer looks exactly the same as transient objects. System automatically brings the objects to and from memory to storage device. (pointer swizzling).
25
Challenges In Building Persistent Languages Efficient caching of objects in client address space.
Cache coherence.
26
Illustra
bought by
Informix IUS
Has had major impact on major commercial DBMS which have all migrated to
ORDBMS model. SQL3 supported by modern databases adapted many of the concepts developed in Postgres
27
POSTGRES Combinations
Introduced object orientation into relation DBMSs. Fundamental Concepts.
Each record has an OID. Access to data though:
query language POSTQUEL. navigation through OIDs.
Classes:
Inheritance: Types: rich set of types available for columns. Functions: can be called within POSTQUEL.
28
Classes:
real: base classes or relations derived: views version: maintained differentially compared to parent class
29
Types In POSTGRES
Standard base types
float, int, charac. Strings, etc. Abstract data type (ADT) facility to create new base types
e.g.;
mailstop
30
from a in answer where. Parent. younger = John or parent. younger = a. older Supported rules
31
32
POSTQUEL Functions
Any collection of commands in POSTQUEL.
query = POSTQUEL function. define function high-pay returns Emp as retrieve (Emp. all) where Emp. salary > 50k
Operators
Arbit C-functions are not optimized by query optimizers.
Special functions - operators can utilize indexes for their evaluation.
Index (e.g.; B-tree) defined properly can be used to speed up evaluation of operators such as AGT.
34
Functions In POSTGRES
Three types: (1) C functions
(2) Operators (3) POSTQUEL functions
C-functions
any C-function over base types or composite type
retrieve (Dept. name) where area (Dept. floorspace) > 500
36
37
Types In POSTGRES
Array type (constructor)
crate Emp ( name = c12, salary = float [12], age = intSalary for each month. )
POSTQUEL query
retrieve (Emp name)
38
Conclusion
OOP festures DBMS features AI features to get Intelligent Databases
39