OSDN Git Service

Use data-type specific conversion functions also in plpy.execute
authorPeter Eisentraut <peter_e@gmx.net>
Thu, 18 Mar 2010 13:23:57 +0000 (13:23 +0000)
committerPeter Eisentraut <peter_e@gmx.net>
Thu, 18 Mar 2010 13:23:57 +0000 (13:23 +0000)
commit12c2f2f66c2d37a951cdf01049d74c520f26e7f9
tree271418a9bc86fa610dec2a7a604d5f924e045df6
parentc21ac0b58e8c3bb050d87e213a6f4524b01b2a6d
Use data-type specific conversion functions also in plpy.execute

In PLy_spi_execute_plan, use the data-type specific Python-to-PostgreSQL
conversion function instead of passing everything through InputFunctionCall
as a string.  The equivalent fix was already done months ago for function
parameters and return values, but this other gateway between Python and
PostgreSQL was apparently forgotten.  As a result, data types that need
special treatment, such as bytea, would misbehave when used with
plpy.execute.
src/pl/plpython/expected/plpython_types.out
src/pl/plpython/expected/plpython_types_3.out
src/pl/plpython/plpython.c
src/pl/plpython/sql/plpython_types.sql