Re: CONSTANT/NOT NULL/initializer properties for plpgsql record variables

2018-01-25 Thread Daniel Gustafsson
> On 25 Jan 2018, at 16:34, Tom Lane wrote: > Daniel Gustafsson writes: >> One tiny thing: while not introduced in this patch, I wonder if it would be >> worth adding an errhint in the following hunk when applied to arrays, to >> clarify what CONSTANT in an

CONSTANT/NOT NULL/initializer properties for plpgsql record variables

2018-01-25 Thread David G. Johnston
On Thursday, January 25, 2018, Tom Lane wrote: > > The documentation currently says > > The CONSTANT option prevents the variable from being assigned to > after initialization, so that its value will remain constant for > the duration of the block. >

Re: CONSTANT/NOT NULL/initializer properties for plpgsql record variables

2018-01-25 Thread Daniel Gustafsson
> On 25 Jan 2018, at 00:32, Tom Lane wrote: > > I wrote: >> I said a couple of times in recent threads that it wouldn't be too hard >> to implement $SUBJECT given the other patches I've been working on. > > Here's a version rebased up to HEAD, with a trivial merge conflict

Re: CONSTANT/NOT NULL/initializer properties for plpgsql record variables

2018-01-24 Thread Tom Lane
I wrote: > I said a couple of times in recent threads that it wouldn't be too hard > to implement $SUBJECT given the other patches I've been working on. Here's a version rebased up to HEAD, with a trivial merge conflict fixed. This now needs to be applied over the patches in

CONSTANT/NOT NULL/initializer properties for plpgsql record variables

2017-12-29 Thread Tom Lane
I said a couple of times in recent threads that it wouldn't be too hard to implement $SUBJECT given the other patches I've been working on. Attached is proof of the pudding. This needs to be applied on top of the patches in https://postgr.es/m/23537.1514589...@sss.pgh.pa.us and