>>>>> On Fri, 10 May 2024 12:25:38 -0400, Phil Stracchino said: > > On 5/10/24 12:15, Phil Stracchino wrote: > > On 5/10/24 07:40, Martin Simmons wrote: > >> No, FileIndex is signed in the File table at least (-ve is used to mark > >> deleted files in an accurate backup). > > > > Then should it not be signed *everywhere*? Or are these just a group of > > disparate columns not used outside their tables that just HAPPEN to all > > have the same name? > > > > And should it be allowed to be NULLable? > > > And FileMedia.FileIndex in particular is just broken. It is currently > declared INT UNSIGNED NOT NULL with no DEFAULT. When no DEFAULT is > specified and STRICT mode is in use the implicit default is NULL, which > gives NOT NULL DEFAULT NULL, which, well .... at least doesn't actually > *crash mysqld* any more. (It used to, in 5.1.)
You've got to love TheirSQL :-) But I think you are mixing two different concepts: in CREATE TABLE, a DEFAULT just specifies what INSERT does if the column is omitted; NOT NULL is a constraint that applies all the time. It is quite reasonable to specify NOT NULL for a column that must always be given a value in an INSERT statement. __Martin _______________________________________________ Bacula-devel mailing list Bacula-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-devel