Re: Vote on SET in aborted transaction

From: Michael Loftis <mloftis(at)wgops(dot)com>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>
Cc: Jan Wieck <janwieck(at)yahoo(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Thomas Lockhart <lockhart(at)fourpalms(dot)org>, Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Vote on SET in aborted transaction
Date: 2002-04-25 01:26:20
Message-ID: 3CC75B3C.2060208@wgops.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hiroshi Inoue wrote:

>What's wrong with it ? The insert command after *rollback*
>would fail. It seems the right thing to me. Otherwise
>the insert command would try to append the data of the
>table t1 to itself. The insert command is for copying
>schema1.t1 to foo.t1 in case the previous create schema
>command suceeded.
>
Exactly, in this example shows exactly why SETs should be part of the
transaction and roll back. Heck the insert may not even fail after all
anyway and insert into the wrong schema. If the insert depends on the
schema create succeeding it should be in the same transaction. (IE it
would get rolled back or not happen at all)

>
>
>regards,
>Hiroshi Inoue
> http://w2422.nsk.ne.jp/~inoue/
>
>---------------------------(end of broadcast)---------------------------
>TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Hiroshi Inoue 2002-04-25 01:28:46 Re: Vote totals for SET in aborted transaction
Previous Message Bruce Momjian 2002-04-25 01:17:39 Re: Vote totals for SET in aborted transaction