Re: pl/pythonu

From: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
To: C G <csgcsg39(at)hotmail(dot)com>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: pl/pythonu
Date: 2004-02-11 16:35:40
Message-ID: Pine.LNX.4.33.0402110934450.32626-100000@css120.ihs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 11 Feb 2004, C G wrote:

> Dear All,
>
> Could anyone explain why this function does will not work? The error message
> is
> DETAIL: exceptions.RuntimeError: maximum recursion depth exceeded.
>
> CREATE FUNCTION testing() RETURNS trigger AS'
>
> plan=plpy.prepare(''INSERT INTO t1 values ($1)'',[''text''])
> plpy.execute(plan,[''blah''])
> return ''MODIFY''
>
> 'LANGUAGE plpythonu;

Perhaps the plpy.execute is inserting into the same table as the trigger
is on? If that's the case, then the trigger will be recursively called
over and over until the "maximum recursion depth" is "exceeded".

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2004-02-11 16:39:16 Re: [GENERAL] dblink - custom datatypes don't work
Previous Message Mark Gibson 2004-02-11 16:33:16 Re: [GENERAL] dblink - custom datatypes don't work