From: Tom Lane <tgl@sss.pgh.pa.us>
To: Marian POPESCU <softexpert@libertysurf.fr>
Cc: pgsql-sql@postgresql.org
Subject: Re: transaction in function
Date: Tue, 05 Dec 2006 11:57:12 -0500
Message-ID: <5992.1165337832@sss.pgh.pa.us> (raw)
In-Reply-To: <el431c$9mt$1@sea.gmane.org>
References: <el431c$9mt$1@sea.gmane.org>
Marian POPESCU <softexpert@libertysurf.fr> writes:
> I want to write a function that updates several tables; if there is an
> exception while updating, it should rollback the transaction and raise an
> error.
> How can this be done in pgPLSQL in PostgreSQL 8.1 ?
You just do it. You would have to work at it to *not* have that behavior.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, softexpert@libertysurf.fr
Subject: Re: transaction in function
In-Reply-To: <5992.1165337832@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox