Does error within transaction imply restarting it?

From: Haroldo Stenger <hstenger(at)adinet(dot)com(dot)uy>
To: postgres general <pgsql-general(at)postgresql(dot)org>
Subject: Does error within transaction imply restarting it?
Date: 2000-04-14 17:55:33
Message-ID: 38F75B95.BA1F8319@adinet.com.uy
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello dear fellows,

I need to get insight about this:

1. A transaction begins
2. LOCK TABLE XYZ; is issued.
3. Since table XYZ doesn't exist, the backend gives error.
4. A CREATE TABLE XYZ(field char); is issued.
5. The backend says that it is in abort state, and that all queries will
be ignored until commit, or end of transaction.

Is this behaviour unavoidable? I mean, can the backend ignore the fact
that I issued a command that yielded an error, and continue accepting
SQL statements within the transaction? Is there a hack or something?

Thank you very much in advance.

Cheers,
Haroldo.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Charles Tassell 2000-04-14 18:02:15 Re: can't connect using the -host option
Previous Message The Hermit Hacker 2000-04-14 17:49:11 Re: database file size bloat