HI all
I have a problem that when i execute an insert statment on a postgres DB the & this get me this error
ERROR JDBCExceptionReporter:78 - Batch entry 0 insert into bankaccounts (BANK_NAME, BANK_CODE, SWIFT_CODE, ACCOUNT_NUMBER, SUB_TYPE, CONTACT_LIST_FK, ID) values (NULL, NULL, Test SwiftCode, 122334, NULL, 2c928a8c1276a26d011276a276690001, 2c928a88132960fd0113296134790001) was aborted. Call getNextException to see the cause.
11:37:22,759 ERROR JDBCExceptionReporter:78 - ERROR: column "sub_type" is of type integer but expression is of type character varying
the first thing come to mind that there is a problem in sub_type column so i removed it from the insert & try the statment directly to the DB then i found the big problem is that when hibernate generates the insert statmens that includes null values it types ' ' but not NULL & the databse accepts this in string values & this itself is not accptable for me.
although i configured the right driver, the right dialact & the sql mapping(androMDA)
thnx for any reply
_________________ best regards,,,
Mohamed Badawy
|