plpython function with dictionary as function argument?

Поиск
Список
Период
Сортировка
От gherzig@fmed.uba.ar
Тема plpython function with dictionary as function argument?
Дата
Msg-id 40270.157.92.152.53.1124462514.squirrel@webmail.fmed.uba.ar
обсуждение исходный текст
Ответы Re: plpython function with dictionary as function argument?  (Peter Fein <pfein@pobox.com>)
Список pgsql-general
Hi all. I need to know if it is possible to call a plpython stored funcion
with an dictionary as single argument:

Suppose this python structure:

someDict = {
            'field1': 'Foo',
            'creepyfield': 'Bar'
            }

The data base connection
CONN = pg.connect()....

I want some pypgslq function

CREATE myfunction ( __dictionary__) returns void
AS
.... (process)
LANGUAGE pythonu

and (the desired goal) be able to execute
CONN.execute("select * from myfunction (someDict)")

It this possible?

Thanks!!
--
Gerardo Herzig
Direccion General de Organizacion y Sistemas
Facultad de Medicina
U.B.A.

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [BUGS] BUG #1830: Non-super-user must be able to copy from a
Следующее
От: Eugene
Дата:
Сообщение: Re: total db lockup