Re: transaction in function

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Marian POPESCU <softexpert(at)libertysurf(dot)fr>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: transaction in function
Date: 2006-12-05 16:57:12
Message-ID: 5992.1165337832@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Marian POPESCU <softexpert(at)libertysurf(dot)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

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Collin Peters 2006-12-05 20:29:26 Question about "AT TIME ZONE"
Previous Message A. Kretschmer 2006-12-05 16:23:19 Re: transaction in function