[Fwd: Re: [GENERAL] newsbie: ORDBMS vs RDBMS] - Mailing list pgsql-advocacy

From Ned Lilly
Subject [Fwd: Re: [GENERAL] newsbie: ORDBMS vs RDBMS]
Date
Msg-id 408D79E3.2060202@nedscape.com
Whole thread Raw
List pgsql-advocacy
Is there somewhere in the docs, websites, etc., that this could be posted?  Seems a good response to an FAQ...


-------- Original Message --------
Subject: Re: [GENERAL] newsbie: ORDBMS vs RDBMS
Date: Mon, 26 Apr 2004 12:27:39 -0400
From: Christopher Browne <cbbrowne@acm.org>
Organization: cbbrowne Computing Inc
To: pgsql-general@postgresql.org
References: <c65l2j$fn4$1@sea.gmane.org>

After takin a swig o' Arrakan spice grog, karadamoglou_k@yahoo.gr ("kostas") belched out:
> I am new to Object Relational DBMS like Postgresql. I want to ask, What is
> the key benefits of ORDBMS over RDBMS. Do you know any link with relevant
> informations. Thank you in advance.

Well, the "key" thing is that PostgreSQL may be extended to support
custom object types.

For instance, it does not, out of the box, support a complex number
type.  (e.g. - values of the form a + b * sqrt(-1)).  You may create a
custom object type to represent complex numbers, and, if you define a
suitable set of operators on it, use "complex" values much as you
would real numbers.

More interesting, perhaps, might be to look at data types that
resemble IP addresses.  PostgreSQL supports a number of network
address types as follows:

http://www.postgresql.org/docs/7.4/interactive/datatype-net-types.html

These types, by being native 'objects,' offer various benefits over
just using a 'dumb string,' notably that:

 a) They offer strong input type checking;

 b) Internally, they can use compact types, such as encoding IP
    addresses into binary integers.  That means that they can be
    manipulated very efficiently by the database engine.

People have created custom object types for such things as:
 - 3D cubes, for visualization applications;
 - UUIDs/GUIDs, to support efficient handling of unique object
   identifiers;
 - ISBN and ISSN numbers (book identifiers)

Efficiency + reliability; strikes me as a win...

The other "object" thing is that PostgreSQL stored procedures offer
what pretty much amounts to multiple dispatch, where you may have a
bunch of procedures with the same name that deal with arguments of
varying types.  It can be a source of grave confusion if you abuse it,
but can be very useful...
--
"cbbrowne","@","ntlug.org"
http://www.ntlug.org/~cbbrowne/linuxxian.html
'You know you've  been hacking too long  if, when someone  asks you if
you have a son, you reply, "No, but I've got a Symbolics 3630".'

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
      joining column's datatypes do not match



pgsql-advocacy by date:

Previous
From: "Merlin Moncure"
Date:
Subject: Re: [HACKERS] What can we learn from MySQL?
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] What can we learn from MySQL?