Re: identity column behavior in WHEN condition for BEFORE EACH ROW trigger

From: Suraj Kharage <suraj(dot)kharage(at)enterprisedb(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: identity column behavior in WHEN condition for BEFORE EACH ROW trigger
Date: 2019-10-07 03:10:48
Message-ID: CAF1DzPWC232K-hzr6_Y5KcvNpKEpTRJzJe4AHT166C5PX-m9hw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> whereas, for identity columns, server allows us to create trigger for same
> and trigger gets invoked as defined. Is this behavior expected? or we need
> to restrict the identity columns in such scenario because anyone one
> override the identity column value in trigger.
>

Also, I think it is breaking the OVERRIDING SYSTEM VALUE clause in INSERT
statement. i.e: without this clause, can insert the modified value from
trigger in identity column. I don't find any document reference for this
behavior.

Thoughts?

--
--

Thanks & Regards,
Suraj kharage,
EnterpriseDB Corporation,
The Postgres Database Company.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2019-10-07 04:04:56 Re: [HACKERS] Block level parallel vacuum
Previous Message Amit Langote 2019-10-07 02:01:13 Re: dropping column prevented due to inherited index