Modern Database Techniques Part 1: Object Oriented Databases - PowerPoint PPT Presentation

1 / 13
About This Presentation
Title:

Modern Database Techniques Part 1: Object Oriented Databases

Description:

Use a class library with an abstract class or interface for persistent objects. ... Examples: ObjectStore, Versant. OODBMS. Application 1. DB. Application 2. 7 ... – PowerPoint PPT presentation

Number of Views:260
Avg rating:3.0/5.0
Slides: 14
Provided by: martin285
Category:

less

Transcript and Presenter's Notes

Title: Modern Database Techniques Part 1: Object Oriented Databases


1
Modern Database TechniquesPart 1 Object
Oriented Databases
  • 3. Different Kinds of OODB

2
Overview
  • OO language persistence
  • Pure OODB
  • DB with object and relational access
  • Object-Relational Databases
  • Object oriented interface to relational databases

3
OO language persistence
  • Use a class library with an abstract class or
    interface for persistent objects.
  • In your application create persistent classes as
    subclasses of that abstract class.
  • Search for objects by object navigation. Write
    code for search yourself.
  • No additional software like a database browser
    provided.
  • Often only one OO language supported. No access
    to data by other languages.

4
OO language persistence
  • Dependent on the special product more or less
    support for transactions or concurrent access
    provided.
  • Advantage Not much overhead
  • Disadvantage Not much functionality
  • Examples GemStone, ozone

PersistanceInterface
Your code
DB
5
Pure OODBMS
  • Pure OODBMS are similar to "OO language
    persistence"
  • They enhance this model considerably
  • OODBMS implement a subset of the ODMG-model
  • Variety of predefined template classes for sets,
    lists, arrays, with appropriate functions
  • Persistent class offers a query-function
  • Transactions, concurrency, logging, recovery,
    constraints, and triggers are supported.
  • Tools for DB-schema development
  • Tools like DB-browser

6
Pure OODBMS (cont.)
  • Advantage Complete DB functionality
  • Disadvantage Often only one or two OO languages
    supported.
  • Examples ObjectStore, Versant

Application 1
OODBMS
DB
Application 2
7
DB with object and relational access
  • Like pure OODBMS and relational databases
  • Two different interfaces to database OO
    interface and SQL interface
  • SQL is also used for DB queries on the object
    side.
  • Advantages
  • Well known query language
  • Support of standard interfaces e. g. ODBC and
    JDBC
  • Disadvantage Not ODMG compliant.

8
DB with object and relational access
  • Examples
  • Caché (InterSystems)
  • Titanium (Savitar Corp.)

Application 3
Application 1
OODBMS
SQL access
DB
Application 2
OO access
9
Object-Relational Databases
  • Object oriented technology on top of relational
    technology and in the relational context.
  • Define types instead of classes. Objects are
    stored in tables of objects rather than in tables
    of rows.
  • Support of major object oriented features
    complex types, inheritance, aggregation, methods
  • Advantage Extension of a well known technology
  • Disadvantages
  • Mixture of both technologies may result in
    difficult to understand schemas
  • Performance problems

10
Object-Tables instead of Tuple-Tables
Tuple-Table Persons
Object-Table Persons
Meier, 1.5.60, ...
Huber, 11.5.69, ...
Miller, 1.12.60, ...
Meier, 7.5.80, ...
Separation of structure definition and table
definition as set of objects instead of set of
tuples
Person_type Name, DateOfBirth, ...
11
Object-Relational Databases
  • Examples
  • Oracle 10g
  • IBM DB2
  • PostgreSQL

12
Object Oriented Interface to Relational Databases
  • Object oriented access to persistent objects
  • Persistent objects stored as rows in relational
    database
  • Mapping of objects to rows transparent to
    application

13
Object Oriented Interface to Relational Databases
  • Advantage Use familiar object oriented
    programming techniques for your applications and
    relational techniques for databases.
  • Disadvantages
  • Mapping not fully transparent
  • Performance problems
  • Example Hibernate

object side
rel. side
insert into persons
Application
DB
relationalDBMS
p.Save()
Write a Comment
User Comments (0)
About PowerShow.com