Brar Piening <brar@gmx.de> writes:
> Tom Lane wrote:
>> PG Bug reporting form <noreply@postgresql.org> writes:
>>> I am using SET LOCAL in an Npgsql multi-statement command.
>> It seems that whatever Npgsql is doing at the wire protocol level
>> doesn't match this, but they'd have to explain what they are doing
>> for us to offer much help.
> At the wire protocol level npgsql sends this as two queries via the
> extended query protocol without a sync inbetween them.
> (Parse,Bind,Describe,Execute;Parse,Bind,Describe,Execute,Sync)
There is no implicit transaction block around the two commands in such
a case, so that explains why it doesn't act as Mike was hoping.
Omitting the Sync has zero effect on transactional semantics; it only
means that if the first command fails, we'll skip the second one.
regards, tom lane