Re: Get affected table name in trigger function?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: emilu(at)encs(dot)concordia(dot)ca
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Get affected table name in trigger function?
Date: 2006-02-13 20:46:44
Message-ID: 4380.1139863604@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Emi Lu <emilu(at)encs(dot)concordia(dot)ca> writes:
> Is it possible to get current table name such as (TG_TABLENAME?) in a
> trigger function?

TG_RELNAME ... or look it up from the table OID TG_RELID ... or pass it
in as a trigger parameter ...

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Eric Chapdelaine 2006-02-13 22:04:09 Unhandled Exception - Executing Samples under win32
Previous Message Emi Lu 2006-02-13 20:31:42 Get affected table name in trigger function?