Bug or feature? COPY ignores column defaults - Mailing list pgsql-hackers

From Oliver Elphick
Subject Bug or feature? COPY ignores column defaults
Date
Msg-id 199901281328.NAA22202@linda.lfix.co.uk
Whole thread Raw
List pgsql-hackers
At release 6.4.2, COPY does not respect column defaults: 

junk=> create table testbed (
junk-> f1 int4 default 5,           
junk-> f2 float default 7.34,
junk-> f3 datetime default now(),
junk-> f4 text default 'default');
CREATE
junk=> copy testbed from stdin;
Enter info followed by a newline
End with a backslash and a period on a line by itself.
>> 
>> \.
junk=> select * from testbed;
f1|f2|f3|f4
--+--+--+--0|  |  |  
(1 row)

INSERT works correctly, however.

Is this intentional, or a bug?

-- 
Oliver Elphick                                Oliver.Elphick@lfix.co.uk
Isle of Wight                              http://www.lfix.co.uk/oliver              PGP key from public servers; key
ID32B8FAA1                ========================================    "Many are the afflictions of the righteous; but
the     LORD delivereth him out of them all."                                                    Psalm 34:19 
 




pgsql-hackers by date:

Previous
From: The Hermit Hacker
Date:
Subject: Re: [HACKERS] new heap manager mmalloc
Next
From: Vadim Mikheev
Date:
Subject: Re: [HACKERS] Bug or feature? COPY ignores column defaults