From: | Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com> |
---|---|
To: | Kevin Way <kevin(dot)way(at)overtone(dot)org> |
Cc: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: trigger trouble -- procedure not found |
Date: | 2001-09-14 05:16:26 |
Message-ID: | Pine.BSF.4.21.0109132214270.39990-100000@megazone23.bigpanda.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
On Fri, 14 Sep 2001, Kevin Way wrote:
> I'm having trouble creating a trigger. First i'm creating a function,
> add_to_search in PL/pgSQL.
>
> \df verifies the existance of this function:
> smallint | add_to_search | text, text, text, integer
>
> but when I call:
>
> CREATE TRIGGER item_insert_search_add AFTER INSERT
> ON item FOR EACH ROW
> EXECUTE PROCEDURE add_to_search (name, description, reason, node_id);
>
> I get:
> ERROR: CreateTrigger: function add_to_search() does not exist
>
> What am I missing here? It seems to me that I'm missing something very
> simple, but I can't figure out what it is for the life of me.
Trigger functions return opaque and take no arguments. Arguments given
on the create trigger statement are passed in a special fashion. (I
believe for plpgsql you'd look at TG_NARGS and TG_ARGV[])
From | Date | Subject | |
---|---|---|---|
Next Message | Kevin Way | 2001-09-14 06:30:07 | Re: trigger trouble -- procedure not found |
Previous Message | Bhuvan A | 2001-09-14 04:59:57 | Re: trigger trouble -- procedure not found |