Skip site navigation (1) Skip section navigation (2)

Re: HI! Problems with cursors into triggers

From: "Robert B(dot) Easter" <reaster(at)comptechnews(dot)com>
To: Andrs Mauricio Marn Restrepo <amarin(at)alpha(dot)telecom-co(dot)net>, pgsql-sql(at)postgresql(dot)org
Subject: Re: HI! Problems with cursors into triggers
Date: 2000-06-28 19:43:09
Message-ID: 00062815473701.00209@comptechnews (view raw or flat)
Thread:
Lists: pgsql-sql
On Wed, 28 Jun 2000, Andrs Mauricio Marn Restrepo wrote:
> 
> HELLO!
> 
> I'm making one trigger (plpgsql) and in the function i use CURSOR for to
> 
> bring an elements and to take them to a variable but no me it does not
> work, WHY?????????????
> 
> The script is:
> 
> DROP TRIGGER miTrig on otro;
> DROP FUNCTION miFunc();
> DROP TABLE otro;
> DROP TABLE cual;
> 
> CREATE TABLE otro (
>     cuenta    integer;
> );
> 
> CREATE TABLE  cual (
>     cuenta1 integer;
>     cuenta2 integer;
> );
> 
> CREATE FUNCTION miFunc () RETURNS OPAQUE AS '
>    DECLARE
>       Cuenta_t INT4;
>    BEGIN
>       begin work;

Can't have nested transactions. Can't use BEGIN/COMMIT within a trigger.

-- 
Robert B. Easter

In response to

pgsql-sql by date

Next:From: Brian PowellDate: 2000-06-28 19:58:33
Subject: Backup of BLOBS
Previous:From: Thomas SwanDate: 2000-06-28 18:50:45
Subject: Finding the names of inheriting classes

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group