Re: Trigger function interface

From: Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>
To: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: Trigger function interface
Date: 2016-01-11 02:56:06
Message-ID: 569319C6.1090400@BlueTreble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 1/7/16 6:15 PM, Tatsuo Ishii wrote:
>> On 1/6/16 7:03 PM, Tatsuo Ishii wrote:
>>> Is it possible to get the parse tree in a C trigger function which is
>>> invoked when DML (INSERT/UPDATE/DELETE against a view) is executed?
>>
>> Yes, it's in fcinfo->flinfo->fn_expr.
>
> Thanks for the info. But is this the parse tree for the top level
> query which involves the trigger?

Hrm, apparently not. fcinfo->context would maybe be helpful, but I'm not
sure.
--
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Kharage, Suraj 2016-01-11 03:52:03 Re: Recovery regression tests
Previous Message Jim Nasby 2016-01-11 02:17:38 Re: Using xmax to detect deleted rows