Re: Suggesting a libpq addition

Andrew Chernow <ac@esilo.com>

From: Andrew Chernow <ac@esilo.com>
To: Marc Balmer <marc@msys.ch>
Cc: pgsql-hackers@postgresql.org
Date: 2010-12-06T03:50:52Z
Lists: pgsql-hackers
On 12/5/2010 4:22 AM, Marc Balmer wrote:
> I am suggesting adding a function to libpq:
>
> PGresult *PQvexec(PGconn *conn, const char *fmt, ...);
>
> It behaves similar to PQexec, but it allows for printf style varargs and
> does connection re-establishing if the connection fails (it can be
> discussed if this already to much magic, maybe remove this part).  It
> has been carefully designed to handle memory the right way.  We use this
> since a long time.
>
> What do you think?
>

I think it is a wonderful idea.  Check out libpqtypes.  It has a PQexecf, 
PQexecvf, PQsendf and PQsendvf.  But that is just the beginning....

http://libpqtypes.esilo.com
http://pgfoundry.org/projects/libpqtypes/
-- 
Andrew Chernow
eSilo, LLC
every bit counts
http://www.esilo.com/