From: Heikki Linnakangas <heikki.linnakangas@iki.fi>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add test case for EEOP_INNER_SYSVAR/EEOP_OUTER_SYSVAR executor o
Date: Tue, 10 Jul 2018 13:17:12 +0000
Message-ID: <E1fcsW0-00058V-4y@gemulon.postgresql.org> (raw)
Add test case for EEOP_INNER_SYSVAR/EEOP_OUTER_SYSVAR executor opcodes.
The EEOP_INNER_SYSVAR and EEOP_OUTER_SYSVAR executor opcodes are not
exercised by normal queries, because setrefs.c will resolve the references
to system columns in the scan nodes already. Join nodes refer to them by
their position in the child node's target list, like user columns.
The only place where those opcodes are used, is in evaluating a trigger's
WHEN condition that references system columns. Trigger evaluation abuses
the INNER/OUTER Vars to refer to the OLD and NEW tuples. The code to handle
the opcodes is pretty straightforward, but it seems like a good idea to
have some test coverage for them, anyway, so that they don't get removed or
broken by accident.
Author: Ashutosh Bapat, with some changes by me.
Discussion: https://www.postgresql.org/message-id/CAFjFpRerUFX=T0nSnCoroXAJMoo-xah9J+pi7+xDUx86PtQmew@mail.gmail...
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/17b715c634d451da3edb221c55c614a7d993c289
Modified Files
--------------
src/test/regress/expected/triggers.out | 10 ++++++++++
src/test/regress/sql/triggers.sql | 10 ++++++++++
2 files changed, 20 insertions(+)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: heikki.linnakangas@iki.fi
Subject: Re: pgsql: Add test case for EEOP_INNER_SYSVAR/EEOP_OUTER_SYSVAR executor o
In-Reply-To: <E1fcsW0-00058V-4y@gemulon.postgresql.org>
References: <E1fcsW0-00058V-4y@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox