From: | Terry Lee Tucker <terry(at)esc1(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: when to use NULL and when to NOT NULL DEFAULT '' |
Date: | 2004-10-08 11:14:33 |
Message-ID: | 200410080714.33321.terry@esc1.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Understood. We use NOT NULL as you have stated below. I just wanted to make
sure we weren't doing something stupid. Thanks for the reply...
On Friday 08 October 2004 07:09 am, David Garamond saith:
> Btw, MySQL manual used to recommend (or still does?) defining all
> columns as NOT NULL as much as possible, "because NULL is slow"... :-)
>
> For me it's pretty obvious, if you are never going to allow the column
> to have an "unknown value", then define it NOT NULL to let the database
> guarantee that. Otherwise, nullable it is.
>
> Terry Lee Tucker wrote:
> > Why would you never define a column as NOT NULL, or am I misunderstanding
> > what you are saying?
> >
> > On Friday 08 October 2004 06:07 am, Peter Eisentraut saith:
> >>Briefly, you always do the first and never do the second.
>
> --
> dave
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if your
> joining column's datatypes do not match
--
Quote: 78
"We have to keep in mind we are a nation under God, and if we ever
forget that, we'll be just a nation under."
--Ronald Reagan
Work: 1-336-372-6812
Cell: 1-336-363-4719
email: terry(at)esc1(dot)com
From | Date | Subject | |
---|---|---|---|
Next Message | Gaetano Mendola | 2004-10-08 11:16:14 | Re: 8.0 questions |
Previous Message | David Garamond | 2004-10-08 11:12:35 | Re: when to use NULL and when to NOT NULL DEFAULT '' |