At 2012-01-11 22:05:34 +0200, pete...@gmx.net wrote:
>
> I propose to add two functions to the result object:
>
> .colnames() returns a list of column names (strings)
> .coltypes() returns a list of type OIDs (integers) […]
>
> Patch attached. Comments welcome.
Applies, builds, passes tests. Co
Peter Eisentraut writes:
> 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.
Fair enough.
> I think we should stick with the PL/Pyt
On ons, 2012-01-11 at 22:52 +0100, Dimitri Fontaine wrote:
> Peter Eisentraut 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
On ons, 2012-01-11 at 17:16 -0300, Alvaro Herrera wrote:
> > I propose to add two functions to the result object:
> >
> > .colnames() returns a list of column names (strings)
> > .coltypes() returns a list of type OIDs (integers)
>
> No typmods?
Didn't think about that, but could be added using
On 11/01/12 22:52, Dimitri Fontaine wrote:
> Peter Eisentraut 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.
>
Peter Eisentraut 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
Excerpts from Peter Eisentraut's message of mié ene 11 17:05:34 -0300 2012:
> There is currently no reliable way to retrieve from a result object in
> PL/Python the number, name, or type of the result columns. You can get
> the number and name if the query returned more than zero rows by looking