pgsql: Add pg_trigger_depth() function

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Add pg_trigger_depth() function
Date: 2012-01-25 16:24:24
Message-ID: E1Rq5e4-00039L-Bw@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox
Thread:
Lists: pgsql-committers

Add pg_trigger_depth() function

This reports the depth level of triggers currently in execution, or zero
if not called from inside a trigger.

No catversion bump in this patch, but you have to initdb if you want
access to the new function.

Author: Kevin Grittner

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/74ab96a45ef6259aa6a86a781580edea8488511a

Modified Files
--------------
doc/src/sgml/func.sgml | 7 ++
src/backend/commands/trigger.c | 21 ++++++-
src/include/catalog/pg_proc.h | 3 +
src/include/commands/trigger.h | 2 +
src/test/regress/expected/triggers.out | 117 ++++++++++++++++++++++++++++++++
src/test/regress/sql/triggers.sql | 64 +++++++++++++++++
6 files changed, 213 insertions(+), 1 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Simon Riggs 2012-01-25 18:02:52 pgsql: Allow pg_basebackup from standby node with safety checking.
Previous Message Bruce Momjian 2012-01-25 14:35:29 pgsql: Now that the shared library name can be adjusted in the library