I'd like to strongly second this. Avoid NULL columns, even at apparent cost.
Having a valid default value is always better. If a design appears to
require NULL values, then the design is likely critically flawed. For
something this simple, a default '' string would be much better.

On 11/26/06, Darren Duncan <[EMAIL PROTECTED]> wrote:

You can save your self a lot of grief by declaring all of your fields
to be NOT NULL and default the text fields to the empty string, ''.
Use '' rather than NULL when you don't have a name.  Then you can
simply say "where foo=''". -- Darren Duncan

At 10:52 PM +0100 11/26/06, Daniel Schumann wrote:
>Hello,
>
>i got a table 't' with two fields for example :
>
>Lastname   |   Name
>---------------------------------
>Duck          |  Donald
>                   |  Peter
>
>with :
>
>SELECT * FROM t WHERE (Lastname='Duck') AND (Name='Donald')
>
>everything is all right
>with :
>
>SELECT * FROM t WHERE (Lastname='') AND (Name='Peter')
>or
>SELECT * FROM t WHERE (Lastname=NULL) AND (Name='Peter')
>
>nothing is selected
>
>what do i wrong ?
>thx



-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]

-----------------------------------------------------------------------------




--
Isaac Raway
Entia non sunt multiplicanda praeter necessitatem.

http://blueapples.org - blog
http://stonenotes.com - personal knowledge management

Reply via email to