In Relational Database you usually create tables where the columns are 
primitive datatypes such as number, varchar2, date (these are oracle 
primitive dataypes).

So... to create a table Customer, for example, you would do something like:

create table customer (
customerID      number(10),
customerName    varchar2(100),
customerStreet  varchar2(50),
customerCity    varchar2(30),
customerState   char(2),
customerZipCode varchar2(10)
);

In an object-Oriented database you can create your own datatypes like:

create type ADDRESS_TY as object(
Street   VARCHAR2(50),
City     VARCHAR2(30),
State    CHAR(2),
Zip      varchar2(10)
);

Then you can create another object that uses this address object like:

create type PERSON_TY as object(
Name     VARCHAR2(100),
Address  ADDRESS_TY
);

Then finally you can create your table like:

create table CUSTOMER(
CustomerID   NUMBER,
Person       PERSON_TY
);

or

create table EMPLOYEE(
EmployeeID   NUMBER,
Person       PERSON_TY
Department   NUMBER
);

See the difference now? The dataype address can be used separatelly in other 
tables directly, or it can be agregated to an object like person_Ty and this 
can be used for many different tables.

The power of this is that your company would define certain datatypes 
instead of expect developer to do it. Work with standards is the first key 
to do a clean job.

Now, imagine different people creating tables as they want. How many 
different words would exist for the same concept.

Street, streetName, address, complement, etc (just for street)
zipCode, zip, zCode (etc...)
What a mess, and this is actually what we see in the market. I consider this 
no professional at all. I always like to tell people that work like that the 
following: "JUST MAKE IT WORK DOES NOT NECESSARILL LEADS TO SUCCESS" .

I have a paper in my web site that is not complete yet, but it gives you 
some idea on how to map java objects directly to Oracle objects.

Remember : IT"S NOT COMPLETE YET, SO YOU MAY FIND SOME ERRORS, OR CODES THAT 
NEED TO BE ADJUSTED TO THE EXAMPLE I POST.

Siomara Pantarotto
www.geocities.com/hisiomara (under tutorials)




>From: "Matthew Patterson" <[EMAIL PROTECTED]>
>Reply-To: <[EMAIL PROTECTED]>
>To: "Mysql list" <[EMAIL PROTECTED]>
>Subject: relational DBMS vs object-relational DBMS
>Date: Wed, 24 Oct 2001 14:33:58 -0500
>
>Everything that I have read describes MySQL as a Relational DataBase
>Management System (RDBMS). PostGreSQL bills itself as an  Object-Relational
>DataBase Management System. Is there a difference between the two and, if
>so, come someone either explain the difference or point me to a resource
>that explains the difference?
>
>Thank you.
>
>Matthew Patterson
>IS Department
>National Support Center, LLC
>Naperville, IL, USA
>http://www.nsc-support.com
>
>***Privacy and Confidentiality Notice***
>The information contained in this E-Mail is intended for the named
>recipients only. It may contain privileged and confidential information and
>if you are not the intended recipient, you must not copy, distribute or 
>take
>any action or reliance on it.
>If you have received this E-Mail in error, please notify the sender
>immediately by using the E-Mail address.
>
>
>
>---------------------------------------------------------------------
>Before posting, please check:
>    http://www.mysql.com/manual.php   (the manual)
>    http://lists.mysql.com/           (the list archive)
>
>To request this thread, e-mail <[EMAIL PROTECTED]>
>To unsubscribe, e-mail 
><[EMAIL PROTECTED]>
>Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
>


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to