java.sql.SQLException: Data size bigger than max size for this type
843859Oct 31 2007 — edited Oct 31 2007Hi all,
i searched for the same kind of post and got the results but my problem is somthing different.
I am using a spring framework to insert data. i have a hashmap which includes the different objects. i m converting this hashmap to byte array using ObjectOutputStream and ByteArrayOutputStream.
now when i try to insert this object to db using ibatis file. it throws following exception
org.springframework.jdbc.UncategorizedSQLException: (SqlMapClientTemplate): encountered SQLException [
--- The error occurred in ibatis/PretradeAnalysis.ibatis.xml.
--- The error occurred while applying a parameter map.
--- Check the savePretradeAnalysis-InlineParameterMap.
--- Check the parameter mapping for the 'blobObject' property.
--- Cause: java.sql.SQLException: Data size bigger than max size for this type: 4248]; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException:
--- The error occurred in ibatis/PretradeAnalysis.ibatis.xml.
--- The error occurred while applying a parameter map.
--- Check the savePretradeAnalysis-InlineParameterMap.
--- Check the parameter mapping for the 'blobObject' property.
--- Cause: java.sql.SQLException: Data size bigger than max size for this type: 4248
com.ibatis.common.jdbc.exception.NestedSQLException:
--- The error occurred in ibatis/PretradeAnalysis.ibatis.xml.
--- The error occurred while applying a parameter map.
--- Check the savePretradeAnalysis-InlineParameterMap.
--- Check the parameter mapping for the 'blobObject' property.
--- Cause: java.sql.SQLException: Data size bigger than max size for this type: 4248
Caused by: java.sql.SQLException: Data size bigger than max size for this type: 4248
4248 is length of my byte array.
please help me.