Subject: Re: [boost] SQL: next iteration of sqlpp11
From: Johan Baltié (johan.baltie_at_[hidden])
Date: 2014-02-03 12:22:27
On Mon, Feb 3, 2014 at 5:56 PM, Klaim - Joël Lamotte <mjklaim_at_[hidden]>wrote:
> On Mon, Feb 3, 2014 at 5:33 PM, Edward Diener <eldiener_at_[hidden]
> > In most usecases I encountered so far, it is totally OK to interpret
> >> NULL values like default values, e.g. NULL strings and empty strings, or
> >> NULL foreign keys or 0LL. For those usecases it would be quite annoying
> >> to have to check if there really is a value, or always use
> >> get_optional_value_or...
> > You are wrong ! Having a database NULL value is completely different from
> > having an empty string or a 0 value. Please reconsider. The
> > is the correct choice.
I do agree.
NULL means "no data", not "0".In SQL "NULL = NULL" is false.
Oracle chose empty string to be equivalent to NULL and it's quite a pain to
handle from a developper point of view.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk