BUG #5614: Varchar column (with DEFAULT NULL) stores 'UL' value instead of null - Mailing list pgsql-bugs

From Mariusz Majer
Subject BUG #5614: Varchar column (with DEFAULT NULL) stores 'UL' value instead of null
Date
Msg-id 201008121508.o7CF815H024532@wwwmaster.postgresql.org
Whole thread Raw
Responses Re: BUG #5614: Varchar column (with DEFAULT NULL) stores 'UL' value instead of null  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
The following bug has been logged online:

Bug reference:      5614
Logged by:          Mariusz Majer
Email address:      mmajer@janmedia.com
PostgreSQL version: 8.3.11
Operating system:   Debian (Linux 2.6.26-1-686-bigmem #1 SMP i686 GNU/Linux)
Description:        Varchar column (with DEFAULT NULL) stores 'UL' value
instead of null
Details:

Varchar column store 'UL' value instead of null

There has been a table ecom2_orders for a while (~0.5m records). After
executing query:

ALTER TABLE ecom2_orders ADD COLUMN password_pdf character varying(50);

when new rows are added, column password_pdf is filled with 'UL' value
rather than null

psql>\d table
(...)
Column description:
password_pdf | character varying(50) | default NULL::character varying

version 8.3.11 - has got above bug
version 8.1.19 - works fine

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #5611: SQL Function STABLE promoting to VOLATILE
Next
From: Robert Haas
Date:
Subject: Re: BUG #5611: SQL Function STABLE promoting to VOLATILE