Re: when to use NULL and when to NOT NULL DEFAULT ''

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Terry Lee Tucker <terry(at)esc1(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: when to use NULL and when to NOT NULL DEFAULT ''
Date: 2004-10-08 12:00:26
Message-ID: 200410081400.26748.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Am Freitag, 8. Oktober 2004 12:20 schrieb Terry Lee Tucker:
> Why would you never define a column as NOT NULL, or am I misunderstanding
> what you are saying?

His question was, should one use null values or should one use artificially
reserved real data values to indicate missing values, as MySQL appears to
have recommended at some point. My suggestion was to use null values.

Of course, if you don't want null values, you declare your column accordingly.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Raymond O'Donnell 2004-10-08 12:01:41 Re: European dates with Win32 version
Previous Message Michael Glaesemann 2004-10-08 11:47:08 Re: when to use NULL and when to NOT NULL DEFAULT ''