Mantis - Resin
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
871 | major | always | 01-17-06 10:06 | 02-02-06 10:09 | |
|
|||||
Reporter: | koreth | Platform: | |||
Assigned To: | ferg | OS: | |||
Priority: | normal | OS Version: | |||
Status: | closed | Product Version: | 3.0.17 | ||
Product Build: | Resolution: | fixed | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 3.0.18 | ||
|
|||||
Summary: | 0000871: Wrong datatype used when EJB container creates an instance with a null LONGVARBINARY column | ||||
Description: |
I have an Oracle table with a LONG RAW column that's allowed to be null. My resin.ejb has the following definition for the field: <cmp-field> <field-name>methodParametersByteArrayField</field-name> <sql-column>methodparameters</sql-column> <abstract-sql-type>LONGVARBINARY</abstract-sql-type> <sql-type>LONG RAW</sql-type> </cmp-field> But the following code gets generated in the __Amber.java file: if (__caucho_super_get_methodParametersByteArrayField() == null) pstmt.setNull(index++, java.sql.Types.DECIMAL); else pstmt.setBytes(index++, __caucho_super_get_methodParametersByteArrayField()); When I try to create a bean instance where the field in question is null, the JDBC call throws an exception with a message from Oracle, "expected BINARY but found NUMBER". Clearly the setNull() call shouldn't be using java.sql.Types.DECIMAL as its data type. |
||||
Steps To Reproduce: | |||||
Additional Information: | |||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|