samedi 10 janvier 2015

SQLAlchemy: query a column for its maximum size


Vote count:

0




Is it possible to query a column for its maximum possible size that can be stored in it? For example, say I declare a column using



content = Column(LargeBinary)


then how can I ask content for its maximum possible size that I can store in? I could need that to check if given data would exceed the store, instead of waiting for the store to fail with



Warning: Data truncated for column 'content' at row 1


asked 34 secs ago

Jens

1,163






SQLAlchemy: query a column for its maximum size

Aucun commentaire:

Enregistrer un commentaire