On Wed, 8 Oct 2014 00:14:51 -0400
Stephen Chrzanowski <[email protected]> wrote:
> When adding a NULL value to a table that has the NOT NULL flag set on
> that field, instead of raising an exception, if the field definition
> were to have the word "USE" between "ON CONFLICT" and "DEFAULT" in
> its declaration, it'd use whatever the fields default value was set
> to. If USE is included, the DEFAULT value must be included,
> otherwise the table isn't created.
I think what you want is usually provided by the DML, not the DDL.
> update ModGroups set ActiveOnServer=null where GroupID = 1;
becomes
update ModGroups set ActiveOnServer=DEFAULT where GroupID = 1;
which is more direct and IMO clearer.
The problem I see with your suggestion is that I can't think of another
situation, with or without NULL, with or without defaults, where
insert into T (t) value (X)
results in T.t = Y. You should get what you asked for, or an error,
not a magical transformation.
--jkl
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users