From: | Jan Urbański <wulczer(at)wulczer(dot)org> |
---|---|
To: | Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr> |
Cc: | Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: PL/Python result metadata |
Date: | 2012-01-11 22:24:28 |
Message-ID: | 4F0E0C1C.9040504@wulczer.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 11/01/12 22:52, 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?
+1 for providing a read-only result.description. Not sure if it's worth
it to follow DB-API there, but maybe yes. Perhaps we could have a
result.description_ex information that's PG-specific or just not present
in PEP 249, like the typmod, collation and so on.
J
From | Date | Subject | |
---|---|---|---|
Next Message | Josh Berkus | 2012-01-11 23:07:35 | Re: [WIP] Double-write with Fast Checksums |
Previous Message | Simon Riggs | 2012-01-11 22:12:31 | Re: 16-bit page checksums for 9.2 |