pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Stephens <bruce@cenderis.demon.co.uk>
To: pgsql-sql@postgresql.org
Subject: Re: [SQL] NULL
Date: 24 Nov 1999 15:08:11 +0000
Message-ID: <87vh6sc4h0.fsf@cenderis.demon.co.uk> (raw)
References: <383059DA.9D2AF70D@kirra.net>
	<87u2mnttmt.fsf@cenderis.demon.co.uk>
	<38315E00.4CDB885F@sferacarta.com>

jose soares <jose@sferacarta.com> writes:

> Bruce Stephens ha scritto:

> > No, it's not required.  This came up before with the examples from
> > "The Practical SQL Handbook".  It would be nice to allow it, but there
> > was some reason why to do so would be non-trivial, which I forget.
> > Anyway, it's not in SQL-92.

> - According with SQL-92 every column can store a NULL value by default
>   unless one specify a NOT NULL constraint for the column.

Yes.  NULL would just mean that NULLs are permitted.  So it's not
required, obviously (since this is the default).  

However, many books recommend that you should generally not allow
NULLs: thus, if you force yourself to explicitly say "NULL" or "NOT
NULL", that ought to be a prompt to consider the issue (and you can
spot cases which you may not have thought about by the absence of
either).  I imagine that's why "The Practical SQL Handbook" suggests
it.



view thread (18+ messages)  latest in thread

Message-ID: <87vh6sc4h0.fsf@cenderis.demon.co.uk>
Permalink:  ../87vh6sc4h0.fsf@cenderis.demon.co.uk/
Also on:    postgresql.org/message-id/87vh6sc4h0.fsf@cenderis.demon.co.uk

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: bruce@cenderis.demon.co.uk
  Subject: Re: [SQL] NULL
  In-Reply-To: <87vh6sc4h0.fsf@cenderis.demon.co.uk>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox