[Opensource] mysql "text" type handled with prepared statement

larry hamel expresso at codeguild.com
Tue Dec 3 18:25:14 PST 2002


hi,

for mysql, all our long text fields in DBObject were defined as type "longvarchar", and our JDBC setup employs the following type mapping

<type-mapping>
        <java-type>LONGVARCHAR</java-type>
        <expresso-type>text</expresso-type>
        <db-type>text</db-type>
</type-mapping>

expresso 5 (latest; haven't checked 5.0.x) has introduced handling for prepared statements, and seems to require handling of both the text and longvarchar types with prepared statements, in particular with the following code in JDBCExecutor (line 484) 

                                if (lobUpdates != null) {
                                        java.sql.PreparedStatement prepStatement = myConnection.createPreparedStatement(theSqlString);


what is the best way around this?  we sacrifice efficiency with prepared statements, according to our previous concensus on this list.

larry




More information about the Opensource mailing list