1 / 13

Modern Database Techniques Part 1: Object Oriented Databases

Modern Database Techniques Part 1: Object Oriented Databases. 3. Different Kinds of OODB. Overview. OO language + persistence Pure OODB DB with object and relational access Object-Relational Databases Object oriented interface to relational databases. OO language + persistence.

galena
Télécharger la présentation

Modern Database Techniques Part 1: Object Oriented Databases

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  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 relationalDBMS DB p.Save()

More Related