python - Django CharField primary key doesn't work, creating rowid primary key automatically -
i using django models sqlite database.
i defined charfield primary key (for example name of attribute a
) physical database synced django
shows primary key rowid
instead of a
.
i tried dropping table , re-sync couple of time still same.
why?
class testtable(models.model): = models.charfield(max_length=10, primary_key=true, db_column='a')
----------------------edit------------------------
django version 1.8.3
Comments
Post a Comment