Re: libpq support for arrays and composites

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Andrew Chernow <ac(at)esilo(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: libpq support for arrays and composites
Date: 2008-06-09 04:31:57
Message-ID: 484CB23D.8010706@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andrew Chernow wrote:
>
> libpqtypes already implemented this. It is a different approach but
> provides the same functionality; with the inclusion of being able to
> handle every data type. libpqtypes uses the PGresult API for
> composites and arrays, rather than adding a new set of functions.
>
>

Yes, I thought you'd say that :-)

This has some significant limitations - for example (quoting from your docs)

Arrays are only handled using binary format. This means that any type
used as an array element must be put and gotten in binary format. If a
user-defined type does not implement a send and recv function in the
backend, it can not be used as an array element.

That makes it quite useless for my intended purpose.

I also am not particularly enamoured of the libpqtypes way of doing things, which feels rather foreign to me.

Lastly, the idea is to provide extra facilities to libpq clients without requiring any extra library.

cheers

andrew

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2008-06-09 06:30:55 Message-ID should surely not be shown as a mailto: URL
Previous Message Tom Lane 2008-06-09 03:10:06 Re: handling TOAST tables in autovacuum