Savepoint Problem

From: Stefan Sturm <mailling(at)anrath(dot)info>
To: PostgreSQL Mailing Lists-General <pgsql-general(at)postgresql(dot)org>
Subject: Savepoint Problem
Date: 2005-01-24 10:32:12
Message-ID: 41F4CEAC.20704@anrath.info
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello,

I have a function, which stores some Data. Sometimes this function is
called within a transaction an sometimes not. But I need to set a
savepoint in this function. But this is my problem, when I'm not in a
transaction I get this error:

ERROR: SAVEPOINT may only be used in transaction blocks

How can I check, if there is an transaction?

Thanks for your help,
Stefan Sturm

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Ralph van Etten 2005-01-24 10:59:42 Re: serialization errors when inserting new records
Previous Message William Yu 2005-01-24 10:28:52 Re: serialization errors when inserting new records