[Pljava-dev] the relation ID of the table on which the trigger occured.

From: thhal at mailblocks(dot)com (Thomas Hallgren)
To:
Subject: [Pljava-dev] the relation ID of the table on which the trigger occured.
Date: 2005-05-25 07:50:26
Message-ID: thhal-0xcZvA9f0zTYJXwu2y5ljtHShqmiCii@mailblocks.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pljava-dev

Marek Lewczuk wrote:

> Hi,
> I think that TriggerData class is missing getRelationID method - this
> should return OID of the table on which the trigger fired. Can I get
> table's OID which fired the trigger in other way ?

The TriggerData.getTableName() will give you the name of the relation.
The TriggerData interface is designed to be as database agnostic as
possible (to allow other vendors to use the same interface) and the
relation OID is very PostgreSQL specific.

We might add a method on the Oid class in the future. Something like:

public static Oid forRelationName(String relationName)

but at present you must use SQL to obtain the OID.

Regards,
Thomas Hallgren

In response to

Responses

Browse pljava-dev by date

  From Date Subject
Next Message Marek Lewczuk 2005-05-25 08:32:59 [Pljava-dev] Re: the relation ID of the table on which the trigger occured.
Previous Message Marek Lewczuk 2005-05-25 07:40:01 [Pljava-dev] the relation ID of the table on which the trigger occured.