Blob fields of variable (possibly huge) size?
Wow, I'm not sure how to advise you, I'd suggest consulting the MySQL documentation and if that doesn't help, seeing about reaching out on whatever support channels they have...or StackOverflow?

If you want to do a LONGBLOB field in peewee, you'll need to add a custom field type for it as blob fields correspond to plain old "BLOB" columns in MySQL. Your code would look like:

``` python
class LongBlobField(BlobField):
    db_field = 'longblob'

db = MySQLDatabase('my_db', fields={'longblob': 'LONGBLOB'})
```

You might also consider storing the blobs externally on the filesystem -- some databases aren't optimized for storing massive values in every row.

Regarding postgres, again you should consult their docs.
 Thanks for the code snipped. Seems to work nicely for me.

Is it possible to create fields of variable (possibly huge) size?
I am currently using `memory_content = BlobField(null=True)`. This seems not to be the right choice as I get

`/opt/Python2.7-32bit/lib/python2.7/site-packages/pymysql/cursors.py:158: Warning: Data truncated for column 'memory_content' at row 1`

 I am using mysql, i.e. the `BlobField()`is translated to a mysql blob.
The mysql docu says:

> A BLOB is a binary large object that can hold a variable amount of data. The four BLOB types are TINYBLOB, BLOB, MEDIUMBLOB, and LONGBLOB. These differ only in the maximum length of the values they can hold.

Do I have to create a custom field as discussed [here](http://docs.peewee-orm.com/en/latest/peewee/models.html#custom-fields)?

Or can I use another already existing field type (maybe CharField?)

Would it be any different with postgresql ?
What is the peewee best practice here?
