Guys,
So I haven't got my question answered, thus trying it again ;)
How do I handle SPI errors properly without rethrowing them or
using subtransactions ? My current code works (simple PG_CATCH()
with resseting of error state), but reports reference leaks for
every failed SPI_exec() call...
Thanks!
Best regards,
Alex Vinogradovs
"Aleksandrs Vinogradovs" <avinogradovs@Clearpathnet.com> writes:
> How do I handle SPI errors properly without rethrowing them or
> using subtransactions ?
Those are your only two choices.
> My current code works (simple PG_CATCH()
> with resseting of error state), but reports reference leaks for
> every failed SPI_exec() call...
The warnings are the least of your worries. Without a subxact abort,
there is all sorts of state that has not been properly cleaned up.
regards, tom lane
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера