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

Re: Passing parameters to a Trigger

From: Antonio Scotti <ascotti(at)mbigroup(dot)it>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Passing parameters to a Trigger
Date: 2003-01-28 09:38:27
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
   Triggers do accept parameters. In fact when you type CREATE TRIGGER 
you can also specify some arguments. They are accessible via trigdata 
not by the standard args of a function (in fact a trigger function must 
not have parameters). The manual makes an example of passing the 
current_user to a trigger, but it is not clear to me. Can anyone explain 
how to make it works?

Antonio Scotti

Josh Berkus ha scritto:

>>I need to pass to a trigger two dynamic text parameters stored into a 
>>table (I can obtain them via a simple select). How can I obtain such a 
>You can't.  Triggers do not accept parameters.
>If the parameters you're talking about are table columns, you can access them 
>through the NEW and OLD record objects.

In response to


pgsql-novice by date

Next:From: Tegge, BerndDate: 2003-01-28 09:41:52
Subject: Re: postgresql with SuSE 8.0
Previous:From: Jonathon BatsonDate: 2003-01-28 07:59:09
Subject: Re: Learning Plpgsql ??

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