Closed moraes closed 11 years ago
For the snippet:
class foo(peewee.Model): id = peewee.IntegerField(primary_key=True) db.compiler().create_table(foo, False)
The SQL generated for a MySQL database was:
CREATE TABLE `foo` (`id` INTEGER NOT NULL PRIMARY KEY)
Should I expect AUTO_INCREMENT to be added to id? I may have misunderstood the docs.
AUTO_INCREMENT
id
I must use PrimaryKeyField. Dooh. Sorry for being so stupid.
For the snippet:
The SQL generated for a MySQL database was:
Should I expect
AUTO_INCREMENT
to be added toid
? I may have misunderstood the docs.