Re: Using transactions with plpythonu

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: imageguy <imageguy1206(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Using transactions with plpythonu
Date: 2007-01-21 13:45:24
Message-ID: 20070121134524.GC2123@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sun, Jan 21, 2007 at 04:56:23AM -0800, imageguy wrote:
> Does anyone have an example of using transactions with plpythonu ?
>
> In my testing so far, it seems that each call to plpy.execute('INSERT
> INTO ....') is committed immediately.

What happens if you do:

plpy.execute("BEGIN");

before and after

plpy.execute("COMMIT");

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Chad Wagner 2007-01-21 13:55:33 Re: More grist for the PostgreSQL vs MySQL mill
Previous Message Martijn van Oosterhout 2007-01-21 13:44:10 Re: [HACKERS] Autovacuum Improvements