Run a transaction block through SPI_execute

Поиск
Список
Период
Сортировка
От mahendrakar s
Тема Run a transaction block through SPI_execute
Дата
Msg-id CABkiuWqsfevi1-GzuNNeqjTMBHMN_HMUmHZOOQZBqLWcY9aU+g@mail.gmail.com
обсуждение исходный текст
Ответы Re: Run a transaction block through SPI_execute  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-novice
When I try to run a transaction block (similar) to below through SPI_execute:
BEGIN; set transaction read write; ....; COMMIT

I get an error: SPI_ERROR_TRANSACTION.

I see that SPI interface does not support transaction manipulation commands.

Documentation:  https://www.postgresql.org/docs/current/spi-spi-execute.html

Can you please suggest me how to achieve run the above transaction
block using SPI_ interface?

Transaction management support only SPI_commit/SPI_rollback.
I'm more interested in setting `set transaction read write;` through
SPI interface.


Thanks,
Mahendrakar.



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

Предыдущее
От: Simon Connah
Дата:
Сообщение: Re: I installed PostgreSQL 16 from the offical Fedora 39 repos - need PostGIS
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Run a transaction block through SPI_execute