Re: Show triggers in psql?

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Bryan Field-Elliot <bryan(at)netmeme(dot)org>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Show triggers in psql?
Date: 2000-09-14 16:02:19
Message-ID: Pine.BSF.4.10.10009140858080.28013-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers


You can get a list of all triggers in the system
as
select * from pg_trigger;

You can get the source for a PL function a trigger
calls with:
select prosrc from pg_trigger,pg_proc where
pg_proc.oid=pg_trigger.tgfoid
and pg_trigger.tgname = '<name>'

[Note, in the case of C functions, I think this
returns the name of the function.]

Stephan Szabo
sszabo(at)bigpanda(dot)com

On Thu, 14 Sep 2000, Bryan Field-Elliot wrote:

> Forgive me if I am missing the obvious, but can someone please tell me how
> to show a list of triggers, or the code in a specific trigger, via the pgsql
> utility?
>
> Thank you,
> Bryan
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Richard Poole 2000-09-14 16:17:04 "initdb -t" ate my baby
Previous Message Bryan White 2000-09-14 15:50:47 Corrupt Table

Browse pgsql-hackers by date

  From Date Subject
Next Message Chris Sterling 2000-09-14 16:44:26 Upgrading from 6.3.2 to 7.0.2
Previous Message Tom Lane 2000-09-14 15:45:27 Re: Dumping views as views?