Re: Postgresql OO Patch - Mailing list pgsql-hackers

From Chris
Subject Re: Postgresql OO Patch
Date
Msg-id 39265812.DAE548C5@bitmead.com
Whole thread Raw
In response to Re: OO Patch  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: [GENERAL] Re: Postgresql OO Patch  (Bruce Momjian <pgman@candle.pha.pa.us>)
Re: Postgresql OO Patch  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
Tom Lane wrote:

> It's kinda fuzzy, but in practice I'd say the readers of pgsql-hackers
> and maybe pgsql-general.

One more time for the <general> mailing list...

Hands up if you have objections to the patch I recently submitted for
postgresql. It fixes the long standing bit-rot / bug  that DELETE and
UPDATE don't work on inheritance hierarchies, and it adds the ONLY
syntax as mentioned in SQL3 and as implemented by Informix. The downside
is it breaks compatibility with the old inheritance syntax. But there is
a backward compatibility mode. I.e. "SELECT * FROM foobar*" becomes
"SELECT * FROM foobar", and "SELECT * from foobar" becomes "SELECT *
FROM ONLY foobar".

Benefits:
*) SQL3 says it.
*) Informix does it.
*) If you never used inheritance it doesn't affect you.
*) Performance is unaffected.
*) There is a backwards compatibility mode via SET.
*) My own experience says strongly that this will greatly reduce
programmer bugs because the default is much more common (laziness
usually leads us to discard the "*" to the detriment of future
inheritance data model changes.)
*) It is more OO since by default a <subclass> IS A <baseclass>.

Disadvantage:
*) You need to make a one line change to any programs that use
inheritance to include the back-compatibility SET mode.

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Sigh: 7.0 pg_dump fails if user table has index on OID
Next
From: Bruce Momjian
Date:
Subject: Re: OO Patch