Re: commit/rollback in postgre 8.2

From: Raymond O'Donnell <rod(at)iol(dot)ie>
To: 'PostgreSQL' <pgsql-general(at)postgresql(dot)org>
Subject: Re: commit/rollback in postgre 8.2
Date: 2009-03-09 11:14:38
Message-ID: 49B4FA1E.5020007@iol.ie
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 09/03/2009 10:34, Ashish Karalkar wrote:
> IPS wrote:
>> Is it possible to use begin, commit and rollback commands within a
>> transaction block in SQL function in postgre ver 8.2
>
> I guess you can use nested blocks in side a function(BEGIN,END) but not
> commit because a SQL function runs as a single transaction.

He could use SAVEPOINT to do something similar -

http://www.postgresql.org/docs/8.2/static/sql-savepoint.html

- though it might or might not work for him, depending on his needs.

Ray.

------------------------------------------------------------------
Raymond O'Donnell, Director of Music, Galway Cathedral, Ireland
rod(at)iol(dot)ie
Galway Cathedral Recitals: http://www.galwaycathedral.org/recitals
------------------------------------------------------------------

Browse pgsql-general by date

  From Date Subject
Next Message Grzegorz Jaśkiewicz 2009-03-09 11:14:57 Re: commit/rollback in postgre 8.2
Previous Message Grzegorz Jaśkiewicz 2009-03-09 11:13:47 Re: Performance of subselects