Re: fixing PQsetvalue() - Mailing list pgsql-hackers

From Robert Haas
Subject Re: fixing PQsetvalue()
Date
Msg-id CA+TgmoZiMReecuwvixVyHddtSm9_M7MYYXhMaktGrt8VvCTeXg@mail.gmail.com
Whole thread Raw
In response to Re: fixing PQsetvalue()  (Pavel Golub <pavel@microolap.com>)
Responses Re: fixing PQsetvalue()
Re: fixing PQsetvalue()
List pgsql-hackers
On Mon, Jul 18, 2011 at 6:38 AM, Pavel Golub <pavel@microolap.com> wrote:
> Hello, Merlin.
>
> I hope it's OK that I've added Andrew's patch to CommitFest:
> https://commitfest.postgresql.org/action/patch_view?id=606
>
> I did this becuase beta3 already released, but nut nothig is done on
> this bug.

So I finally got around to taking a look at this patch, and I guess my
basic feeling is that I like it.  The existing code is pretty weird
and inconsistent: the logic in PQsetvalue() basically does the same
thing as the logic in pqAddTuple(), but incompatibly and less
efficiently.  Unifying them seems sensible, and the fix looks simple
enough to back-patch.

With respect to Tom's concern about boxing ourselves in, I guess it's
hard for me to get worried about that.  I've heard no one suggest
changing the internal representation libpq uses for result sets, and
even if we did, presumably the new format would also need to support
an "append a tuple" operation - or the very worst we could cause it to
support that without much difficulty.

So, +1 from me.

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


pgsql-hackers by date:

Previous
From: Josh Kupershmidt
Date:
Subject: Re: patch: Allow \dd to show constraint comments
Next
From: Josh Kupershmidt
Date:
Subject: Re: patch: Allow \dd to show constraint comments