Re: Should we drop the "object" from ORDBMS?

From: Brendan Jurd <direvus(at)gmail(dot)com>
To: Jeff Davis <pgsql(at)j-davis(dot)com>
Cc: pgsql-advocacy(at)postgresql(dot)org
Subject: Re: Should we drop the "object" from ORDBMS?
Date: 2012-04-26 06:34:23
Message-ID: CADxJZo3oKYr_WBFjtag8ytE2HwF2YpW9QG3xMqaf1fevp9+rsg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-advocacy

On 26 April 2012 16:02, Jeff Davis <pgsql(at)j-davis(dot)com> wrote:
> As far as I can tell, postgresql has the following object-relational
> features:
>
...

> (3) Dot function call syntax: "select foo.count from foo" -- surprising
> to most people, and I don't recall ever seeing it suggested for actual
> use. I would go so far as to say we should deprecate this syntax,
> because I think it's more likely to be some kind of mistake than
> anything else.

Sometime in the distant past (can't find it now), I raised the idea of
having "methods" registered on a table. If we are to pursue the
analogy of a table being like an object class, and a record being like
an object instance, well we've got the attributes covered, but we
don't have the methods. My pipedream was that these methods could be
listed in \d and executed using dot call syntax. So you could define
something like "FUNCTION age_years(person, date) RETURNS int" and then
call it like:

SELECT p.age_years(date '2012-05-01')
FROM person p

As I recall, my idea did not achieve escape velocity, but I still
think it would a) extend the dot-call syntax to a more useful pattern,
b) bolster our justification for the "O" in "ORDBMS", and c) actually
be kind of awesome.

On the broader question, I think you're right that our "O" is a little
bit tenuous. But I take that as an incentive to make Postgres more
object-y, rather than an incentive to drop the "O".

Cheers,
BJ

In response to

Responses

Browse pgsql-advocacy by date

  From Date Subject
Next Message Chris Travers 2012-04-26 07:00:33 Re: Should we drop the "object" from ORDBMS?
Previous Message Jeff Davis 2012-04-26 06:02:19 Should we drop the "object" from ORDBMS?