? patch
Index: doc/src/sgml/plperl.sgml
===================================================================
RCS file: /projects/cvsroot/pgsql/doc/src/sgml/plperl.sgml,v
retrieving revision 2.52
diff -c -r2.52 plperl.sgml
*** doc/src/sgml/plperl.sgml	10 Mar 2006 19:10:48 -0000	2.52
--- doc/src/sgml/plperl.sgml	25 May 2006 18:49:34 -0000
***************
*** 728,734 ****
      </varlistentry>
  
      <varlistentry>
!      <term><literal>$_TD-&gt;{relname}</literal></term>
       <listitem>
        <para>
         Name of the table on which the trigger fired
--- 728,734 ----
      </varlistentry>
  
      <varlistentry>
!      <term><literal>$_TD-&gt;{table_name}</literal></term>
       <listitem>
        <para>
         Name of the table on which the trigger fired
***************
*** 737,742 ****
--- 737,760 ----
      </varlistentry>
  
      <varlistentry>
+      <term><literal>$_TD-&gt;{relname}</literal></term>
+      <listitem>
+       <para>
+        Name of the table on which the trigger fired. This has been deprecated. Please use $_TD-&gt;{table_name} instead.
+       </para>
+      </listitem>
+     </varlistentry>
+ 
+     <varlistentry>
+      <term><literal>$_TD-&gt;{table_schema}</literal></term>
+      <listitem>
+       <para>
+        Name of the schema in which the table on which the trigger fired, is
+       </para>
+      </listitem>
+     </varlistentry>
+ 
+     <varlistentry>
       <term><literal>$_TD-&gt;{argc}</literal></term>
       <listitem>
        <para>
Index: src/pl/plperl/plperl.c
===================================================================
RCS file: /projects/cvsroot/pgsql/src/pl/plperl/plperl.c,v
retrieving revision 1.108
diff -c -r1.108 plperl.c
*** src/pl/plperl/plperl.c	4 Apr 2006 19:35:37 -0000	1.108
--- src/pl/plperl/plperl.c	25 May 2006 18:49:37 -0000
***************
*** 525,530 ****
--- 525,536 ----
  	hv_store(hv, "relname", 7,
  			 newSVpv(SPI_getrelname(tdata->tg_relation), 0), 0);
  
+ 	hv_store(hv, "table_name", 10,
+ 			 newSVpv(SPI_getrelname(tdata->tg_relation), 0), 0);
+ 
+ 	hv_store(hv, "table_schema", 12,
+ 			 newSVpv(SPI_getnspname(tdata->tg_relation), 0), 0);
+ 
  	if (TRIGGER_FIRED_BEFORE(tdata->tg_event))
  		when = "BEFORE";
  	else if (TRIGGER_FIRED_AFTER(tdata->tg_event))
