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

From: Kevin Grittner
Subject: Re: Should we drop the "object" from ORDBMS?
Date: ,
Msg-id: 4F98F56F02000025000473B2@gw.wicourts.gov
(view: Whole thread, Raw)
In response to: Should we drop the "object" from ORDBMS?  (Jeff Davis)
Responses: Re: Should we drop the "object" from ORDBMS?  (Jeff Davis)
List: pgsql-advocacy

Tree view

Should we drop the "object" from ORDBMS?  (Jeff Davis, )
 Re: Should we drop the "object" from ORDBMS?  (Brendan Jurd, )
  Re: Should we drop the "object" from ORDBMS?  (Chris Travers, )
   Re: Should we drop the "object" from ORDBMS?  (Brendan Jurd, )
 Re: Should we drop the "object" from ORDBMS?  ("Kevin Grittner", )
  Re: Should we drop the "object" from ORDBMS?  (Jeff Davis, )
 Re: Should we drop the "object" from ORDBMS?  (Peter Eisentraut, )
  Re: Should we drop the "object" from ORDBMS?  (Ned Lilly, )
  Re: Should we drop the "object" from ORDBMS?  (Jeff Davis, )
   Re: Should we drop the "object" from ORDBMS?  (Pavel Stehule, )
 Re: Should we drop the "object" from ORDBMS?  (Josh Berkus, )
  Re: Should we drop the "object" from ORDBMS?  (Jeff Davis, )
   Re: Should we drop the "object" from ORDBMS?  (Josh Berkus, )
    Re: Should we drop the "object" from ORDBMS?  (Josh Berkus, )
  Re: Should we drop the "object" from ORDBMS?  (Darren Duncan, )

Chris Travers  wrote:

>>> (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.

> Dot syntax should be replaced by something less ambiguous, though.
> The problem is that you currently have issues in some versions of
> Pg where p.name might be the name of the person, or it might be the
> p record cast as something almost identical to varchar(63).......
> The only reason this is not an issue on more recent versions of Pg
> is that implicit casting to text types has been dropped so this
> doesn't really address the underlying problem.

We use dot syntax heavily, and I consider it a valuable feature.  For
example, names are stored in our database with separate columns for
last name, first name, middle name, suffix (Jr., III, etc.), but we
want to put those together in a canonical form for searching.  Prior
to PostgreSQL we have a trigger-maintained column in the database for
this for each name.  With PostgreSQL we were able to replace the
column with a function without changing any of our application code
or the queries they use.

I would be very unhappy to see this feature deprecated or removed.  I
would much rather see functions which qualify as "generated columns"
(i.e., they have as their only parameter the record type of a table)
listed in the \d display for a table.

Let's not break things which work just fine now.

-Kevin


pgsql-advocacy by date:

From: "Kevin Grittner"
Date:
Subject: Re: Should we drop the "object" from ORDBMS?
From: Peter Eisentraut
Date:
Subject: Re: Should we drop the "object" from ORDBMS?