Just curious because it doesn't seem to stop a longer string from being stored in the DB like I expected it to.
Why even define it if it doesn't matter? (it must do something!)
class Message(db.Model):
id = db.Column(db.Integer, primary_key = True)
tag = db.Column(db.String(12))
description = db.Column(db.String(120))
copy = db.Column(db.String)
voice = db.Column(db.String(24))
As Daniel suggested, I'm using SQLite, which does not enforce column lengths.
Thanks Daniel!
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments