I thought this was a scope problem, but it seems to be even bigger. This is the error I get: OperationalError: (OperationalError) (1067, "Invalid default value for 'date_created'") u'\nCREATE TABLE fu_op_requests (\n \tfu_op_requests_id INTEGER NOT NULL AUTO_INCREMENT, \n\tname VARCHAR(50), \n\trequested_items VARCHAR(300), \n\tamount_donated FLOAT(4), \n\tcomments VARCHAR(300), \n\tdate_created DATETIME DEFAULT now() NOT NULL, \n\tPRIMARY KEY (fu_op_requests_id)\n)\n\n' {}
Wow, how could it be generating a DATETIME DEFAULT now() raw command from this syntax? from sqlalchemy.databases import mysql purchases_table = sqlalchemy.Table('fu_op_purchases', metadata, sqlalchemy.Column('fu_op_purchases_id', sqlalchemy.Integer, primary_key=True), sqlalchemy.Column('name', sqlalchemy.String(50)), sqlalchemy.Column('purchased_item', sqlalchemy.VARCHAR(300)), sqlalchemy.Column('price', sqlalchemy.Float(4)), sqlalchemy.Column('comments', sqlalchemy.VARCHAR(300)), sqlalchemy.Column('date_created', mysql.MSTimeStamp, sqlalchemy.PassiveDefault(sqlalchemy.text("CURRENT_TIMESTAMP")), nullable=False)) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to sqlalchemy@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en -~----------~----~----~----~------~----~------~--~---