Re: plpython returns integer[] fails for multi-dimensional array - Mailing list pgsql-general

From Peter Geoghegan
Subject Re: plpython returns integer[] fails for multi-dimensional array
Date
Msg-id AANLkTi==m0mnO2ZkRTJEbyn1h3jHLm5Wmp9_b5ePs6K_@mail.gmail.com
Whole thread Raw
In response to Re: plpython returns integer[] fails for multi-dimensional array  (Thom Brown <thom@linux.com>)
Responses Re: plpython returns integer[] fails for multi-dimensional array  (Adrian Klaver <adrian.klaver@gmail.com>)
List pgsql-general
On 21 December 2010 23:17, Thom Brown <thom@linux.com> wrote:
> Are you sure that "a" returns okay in that scenario.  You're using a
> list.  Shouldn't you be using an array?  Like: a = []

a =[] actually declares an empty list in Python. You can return a list
or a tuple from a pl/python function in 9.0 and it will be interpreted
as an array at the SQL call site. You cannot in prior versions.

--
Regards,
Peter Geoghegan

pgsql-general by date:

Previous
From: Thom Brown
Date:
Subject: Re: plpython returns integer[] fails for multi-dimensional array
Next
From: Satoshi Nagayasu
Date:
Subject: Re: Understanding PG9.0 streaming replication feature