From: | Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
---|---|
To: | Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Test for trigger condition accessing system attributes |
Date: | 2018-07-10 13:17:50 |
Message-ID: | 16d84c11-3dd9-c13d-1692-85ada401f05a@iki.fi |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 10/05/18 11:58, Ashutosh Bapat wrote:
> Hi,
> I was investigating the cases when the system attributes are accessed
> beyond the scans. After investigating set_plan_references(), I thought
> that we never access system attributes beyond scans. This lead me to
> assume that EEOP_INNER/OUTER_SYSVAR are not needed since we do not
> access system attributes from an inner or outer slot. I removed the
> defintions and code using those and ran regression. All the tests
> passed. So, I was about to conclude that my assumption is correct. But
> then looking at TriggerEnabled() I realised that we also (ab?)use
> INNER/OUTER Vars for OLD/NEW tuples for trigger condition. If the WHEN
> condition in CREATE TRIGGER command refers to a system attribute, we
> will end up having INNER/OUTER var refering a system attribute, thus
> exercising code for EEOP_INNER/OUTER_SYSVAR.
>
> Here's patch containing a testcase exercizing that code using
> EEOP_INNER/OUTER_SYSVAR.
Pushed with some small changes. Thanks!
- Heikki
From | Date | Subject | |
---|---|---|---|
Next Message | Ashutosh Bapat | 2018-07-10 13:19:30 | Re: Test for trigger condition accessing system attributes |
Previous Message | Ashutosh Bapat | 2018-07-10 13:17:41 | Re: [PATCH] Add support for ON UPDATE/DELETE actions on ALTER CONSTRAINT |