[Lazarus] Lazarus, Jedi etc.

Henry Vermaak henry.vermaak at gmail.com
Mon Jul 15 17:40:01 CEST 2013

On Mon, Jul 15, 2013 at 04:34:21PM +0100, Henry Vermaak wrote:
> On Mon, Jul 15, 2013 at 03:44:42PM +0100, Graeme Geldenhuys wrote:
> > On 2013-07-15 15:06, Henry Vermaak wrote:
> > > Could you explain why the above is bad for those of us that aren't DB
> > > experts?  To my untrained eye it looks fairly plausible, so I'm
> > > obviously missing something.
> > 
> > I never inserted data into column C, so MySQL decided on its own that it
> > should magically contain the value 0 — inventing data! Last time I
> > checked 0 <> null in SQL terms either.
> I seem to remember something about table columns having default values
> in the definition, so perhaps column C defaults to 0?  0 != NULL, so it
> didn't break your definition?

Just checked the docs:

"If you are not running in strict SQL mode, any column not explicitly
given a value is set to its default (explicit or implicit) value.
If you want an INSERT statement to generate an error unless you
explicitly specify values for all columns that do not have a default
value, you should use strict mode."

Seems fair enough to me?

More information about the Lazarus mailing list