Re: SQL queries inside a C function?

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: SQL queries inside a C function?
Дата
Msg-id AANLkTimDhthXBBQ=9ehB1D0RXcQQSaEQ9xybHJmTM+DX@mail.gmail.com
обсуждение исходный текст
Ответ на SQL queries inside a C function?  (Elliot Chance <elliotchance@gmail.com>)
Список pgsql-general
Hello

you can use a SPI interface

http://www.postgresql.org/docs/9.0/interactive/spi.html

regards

Pavel Stehule

2010/12/26 Elliot Chance <elliotchance@gmail.com>:
> Hi everyone,
>
> How do I get the active connection handle from inside a C function linked as a PL/pgSQL function, like:
>
> Datum pg_do_something(PG_FUNCTION_ARGS)
> {
>  PGconn *conn = ....?
>  // now do some SELECTs / INSERTs
>  PG_RETURN_INT32(result);
> }
>
> Thanks,
> Elliot
> --
> Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

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

Предыдущее
От: Elliot Chance
Дата:
Сообщение: SQL queries inside a C function?
Следующее
От: Satoshi Nagayasu
Дата:
Сообщение: Re: why update is slower on my pc?