Re: multiset patch review

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Itagaki Takahiro <itagaki(dot)takahiro(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Subject: Re: multiset patch review
Date: 2011-01-30 16:52:39
Message-ID: AANLkTi=_QjKU7L5AXLFVBZXS3H0Fqhtee4S+GJA4V6--@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Jan 24, 2011 at 7:27 AM, Itagaki Takahiro
<itagaki(dot)takahiro(at)gmail(dot)com> wrote:
> On Mon, Jan 24, 2011 at 20:49, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
>> I notice that this is adding keywords and syntax support for what is
>> basically a PostgreSQL extension (since we certainly can't possibly be
>> following the SQL standards given that we're not implementing a new
>> datatype.  Is that really a good idea?
>
> As I wrote here,
> http://archives.postgresql.org/pgsql-hackers/2011-01/msg00829.php
> I think we can follow the SQL standard incrementally because we
> have function overloads.
>
> One exception is the result type of collect() aggregate function.
> It returns an array for now, but will return a multiset when we
> support true multiset data type.

So, the plan is to add this now with non-standard semantics and then
change the semantics later if and when we implement what the standard
requires? That's not something we usually do, and I don't see why
it's a better idea in this case than it is in general. It's OK to
have non-standard behavior with non-standard syntax, but I think
non-standard behavior with standard syntax is something we want to try
hard to avoid.

I'm in favor of rejecting this patch in its entirety. The
functionality looks useful, but once you remove the syntax support, it
could just as easily be distributed as a contrib module rather than in
core.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2011-01-30 17:16:51 Re: multiset patch review
Previous Message Magnus Hagander 2011-01-30 16:52:00 Re: mingw 64 build