[sqlalchemy] Re: Problem with non-null fields

2008-05-09 Thread jason kirtland
TP wrote: Hi, I have a model with a field called 'name' that is set to be non- null. When I look at the actual table created in MySQL the field really does say it cannot be null. However, when I try to set it to None and commit() the changes, I get a warning printed

[sqlalchemy] Re: Problem with non-null fields

2008-05-09 Thread TP
Who knew that marking a field as non-null didn't really make it non- null? Apparently you have to add the following to your my.cnf to tell MySQL your're actually serious about enforcing things: sql-mode='STRICT_TRANS_TABLES' On May 9, 11:30 am, jason kirtland [EMAIL PROTECTED] wrote: TP wrote: