You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Jonathon -- Improov <jo...@improov.com> on 2007/04/23 06:32:35 UTC

MySQL fieldtype mapping not equivalent with PostgreSQL's?

The mapping for data type "blob" in OFBiz translates to PostgreSQL's BYTEA and MySQL's BLOB.

While BYTEA has max length of 256^4 - 1, BLOB has 256^2 - 1. In PostgreSQL, entities like 
VideoDataResource can hold around 4GB of data; in MySQL, it's barely 65KB.

PostgreSQL BYTEA: http://www.postgresql.org/docs/7.2/static/datatype-binary.html

MySQL BLOB: http://www.htmlite.com/mysql003.php

The fix is in /framework/entity/fieldtype/fieldtypemysql.xml . The correct equivalent in MySQL is 
LONGBLOB, not BLOB.

It seems OFBiz was developed with PostgreSQL, not MySQL. Is it worthwhile for me to move OFBiz to 
true compatibility with or support for MySQL? There are various other bugs related to 
incompatibilities between OFBiz and MySQL, the XAPoolDatasource issue being one of them (in which 
case, it's also a possible issue with MSSQL and many other decent RDBMSes).

Jonathon