Re: On enforcing default column value, AKA "Bloody nulls"

2025-01-16 Thread hubert depesz lubaczewski
On Thu, Jan 16, 2025 at 12:14:54PM +, Wiwwo Staff wrote: > Hi all! > In a scenario like this: > > > =# create table tab1(text1 text default 'from table'); > > > > =# create procedure ins_tab1(p_text1 text default 'from proc') language > sql as > > -# $$ > > $# insert into tab1(text1) values (p

On enforcing default column value, AKA "Bloody nulls"

2025-01-16 Thread Wiwwo Staff
Hi all! In a scenario like this: > =# create table tab1(text1 text default 'from table'); > > =# create procedure ins_tab1(p_text1 text default 'from proc') language sql as > -# $$ > $# insert into tab1(text1) values (p_text1); > $# $$; > > =# call ins_tab1 (null); > > =# select * from tab1 ; >