From: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
---|---|
To: | Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr> |
Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: PL/Python result metadata |
Date: | 2012-01-16 18:46:31 |
Message-ID: | 1326739591.29466.4.camel@vanquo.pezone.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On ons, 2012-01-11 at 22:52 +0100, Dimitri Fontaine wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > .colnames() returns a list of column names (strings)
> > .coltypes() returns a list of type OIDs (integers)
> >
> > I just made that up because there is no guidance in the other standard
> > PLs for this sort of thing, AFAICT.
>
> What about having the same or comparable API as in psycopg or DB API
>
> http://initd.org/psycopg/docs/cursor.html
>
> You could expose a py.description structure?
I deliberately chose not to do that, because the PL/Python API is
intentionally totally different from the standard DB-API, and mixing in
some semi-conforming look-alike would be quite confusing from both ends.
I think we should stick with the PL/Python API being a small layer on
top of SPI, and let the likes of plpydbapi handle the rest.
From | Date | Subject | |
---|---|---|---|
Next Message | Magnus Hagander | 2012-01-16 18:47:17 | Re: pgstat documentation tables |
Previous Message | Peter Eisentraut | 2012-01-16 18:44:05 | Re: PL/Python result metadata |