Thomas Hallgren <thhal@mailblocks.com> writes:
> Tom Lane wrote:
>> You do realize that SPI_execute will reject TransactionStmt anyway?
>> The example is therefore not very compelling ...
>>
> It won't reject savepoint related statements and that's what the example
> is for.
Really?
if (queryTree->commandType == CMD_UTILITY)
{
...
else if (IsA(queryTree->utilityStmt, TransactionStmt))
{
res = SPI_ERROR_TRANSACTION;
goto fail;
}
}
Looks pretty rejectish to me...
regards, tom lane