postgresql/src/pl/plpython/expected
Peter Eisentraut 3ab8b7fa6f Fix/improve bytea and boolean support in PL/Python
Before, PL/Python converted data between SQL and Python by going
through a C string representation.  This broke for bytea in two ways:

- On input (function parameters), you would get a Python string that
  contains bytea's particular external representation with backslashes
  etc., instead of a sequence of bytes, which is what you would expect
  in a Python environment.  This problem is exacerbated by the new
  bytea output format.

- On output (function return value), null bytes in the Python string
  would cause truncation before the data gets stored into a bytea
  datum.

This is now fixed by converting directly between the PostgreSQL datum
and the Python representation.

The required generalized infrastructure also allows for other
improvements in passing:

- When returning a boolean value, the SQL datum is now true if and
  only if Python considers the value that was passed out of the
  PL/Python function to be true.  Previously, this determination was
  left to the boolean data type input function.  So, now returning
  'foo' results in true, because Python considers it true, rather than
  false because PostgreSQL considers it false.

- On input, we can convert the integer and float types directly to
  their Python equivalents without having to go through an
  intermediate string representation.

original patch by Caleb Welton, with updates by myself
2009-09-09 19:00:09 +00:00
..
plpython_drop.out Convert the existing regression test scripts for the various optional 2005-05-14 17:55:22 +00:00
plpython_error.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_error_2.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_global.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_import.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_newline.out Split the plpython regression test into test cases arranged by topic, instead 2009-08-12 16:37:26 +00:00
plpython_params.out Augment test coverage in PL/Python, especially for error conditions. 2009-08-13 20:50:05 +00:00
plpython_populate.out Convert the existing regression test scripts for the various optional 2005-05-14 17:55:22 +00:00
plpython_record.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
plpython_schema.out Augment test coverage in PL/Python, especially for error conditions. 2009-08-13 20:50:05 +00:00
plpython_setof.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_spi.out Use generic attribute management in PL/Python 2009-08-25 08:14:42 +00:00
plpython_test.out Make PL/Python tests more compatible with Python 3 2009-08-24 20:25:25 +00:00
plpython_trigger.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
plpython_types.out Fix/improve bytea and boolean support in PL/Python 2009-09-09 19:00:09 +00:00
plpython_unicode.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
plpython_unicode_2.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
plpython_unicode_3.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
plpython_void.out Enhanced error context support in PL/Python 2009-08-25 12:44:59 +00:00
README Split the plpython regression test into test cases arranged by topic, instead 2009-08-12 16:37:26 +00:00

Guide to alternative expected files:

plpython_error_2.out		Python 2.2, 2.3, 2.4
plpython_error.out			Python 2.5, 2.6

plpython_unicode_2.out		Python 2.2
plpython_unicode_3.out		Python 2.3, 2.4
plpython_unicode.out		Python 2.5, 2.6