Does error within transaction imply restarting it? - Mailing list pgsql-general

From Haroldo Stenger
Subject Does error within transaction imply restarting it?
Date
Msg-id 38F75B95.BA1F8319@adinet.com.uy
Whole thread Raw
List 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.

pgsql-general by date:

Previous
From: The Hermit Hacker
Date:
Subject: Re: database file size bloat
Next
From: Thomas Reinke
Date:
Subject: Re: Postgresqlism & Vacuum?