Received: from sss.pgh.pa.us (sss.pgh.pa.us [216.151.103.158]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f3PKRo376424 for ; Wed, 25 Apr 2001 16:27:50 -0400 (EDT) (envelope-from tgl@sss.pgh.pa.us) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.3/8.11.3) with ESMTP id f3PKRfR05698; Wed, 25 Apr 2001 16:27:41 -0400 (EDT) To: "Curtis H. Wilbar Jr." cc: pgsql-docs@postgresql.org Subject: Re: Question regardding info available in customer C trigger function In-reply-to: <200104250105.VAA03355@fury.cw.ici.net> References: <200104250105.VAA03355@fury.cw.ici.net> Comments: In-reply-to "Curtis H. Wilbar Jr." message dated "Tue, 24 Apr 2001 21:13:11 -0400" Date: Wed, 25 Apr 2001 16:27:41 -0400 Message-ID: <5695.988230461@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200104/78 X-Sequence-Number: 650 "Curtis H. Wilbar Jr." writes: > However, is there a way in my C function to determine the name of the > table and of the database that caused the trigger. The current database name is not passed around as a parameter, but you can get it from the global variable DatabaseName. As for the table name, try RelationGetRelationName(triggerdata->tg_relation). regards, tom lane