1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-25 01:02:05 +03:00

PL/Python: Add result object str handler

This is intended so that say plpy.debug(rv) prints something useful for
debugging query execution results.

reviewed by Steve Singer
This commit is contained in:
Peter Eisentraut
2013-02-03 00:31:01 -05:00
parent d2d153fdb0
commit 330ed4ac6c
4 changed files with 61 additions and 1 deletions

View File

@ -956,6 +956,17 @@ foo = rv[i]["my_column"]
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><literal><function>__str__</function>()</literal></term>
<listitem>
<para>
The standard <literal>__str__</literal> method is defined so that it
is possible for example to debug query execution results
using <literal>plpy.debug(rv)</literal>.
</para>
</listitem>
</varlistentry>
</variablelist>
</para>