Version information
- Release date: October 21, 2024
- Version: V2.4.13
Overview
OceanBase Connector/J V2.4.13 can implement the Statement.getGeneratedKeys() method by supporting the RETURNING ... INTO ... clause based on the ArrayBinding feature in Oracle mode. The Statement.getGeneratedKeys() method can be used to obtain the result set of batch operations. The impact of user-defined type (UDT) caching on the driver is eliminated. Moreover, a series of serious bugs are fixed to improve the stability of OceanBase Connector/J. For example, the new version fixes the issue where null is returned by the getMetaData() method when the text protocol is enabled or when both the PreparedStatement and PrepareExecute protocols are enabled.
New features
- OceanBase Connector/J V2.4.13 enhances the ArrayBinding feature, which was introduced in OceanBase Connector/J V2.2.11. The new version implements the
Statement.getGeneratedKeys()method by supporting theRETURNING ... INTO ...clause based on the ArrayBinding feature in Oracle mode. TheStatement.getGeneratedKeys()method can be used to obtain the result set of batch operations. To do so, you must configurecompatibleOjdbcVersion=8&useArrayBinding=true&useOraclePrepareExecute=true.
Bug fixes
This version fixes the following bugs:
- Fixed the issue where
nullis returned if thegetMetaData()method is called after a prepared statement is executed withuseServerPrepStmtsset tofalse. - Fixed the issue where the "not support batch operation for DML_Returning_Into feature" error is returned when
ps.addBatch()andRETURNING INTOare used. - Fixed the issue where statements are repeatedly executed if the value of
maxBatchTotalParamsNumis smaller than the actual number of parameters anduseServerPrepStmts=trueis configured when theexecuteBatch()method is called. - Fixed the issue where blocking occurs when an invalid column index is used to retrieve the return results.
- Fixed the issue where the
NumberFormatExceptionerror may be returned if a UDT is changed from the collection type to the object type. - Fixed the issue where an error occurs when stored procedures return data of a complex type (an array of UDTs) in the JDBC driver, but the UDT definition changes.
- Fixed the issue where an
ArrayIndexOutOfBoundsExceptionis thrown during execution if the definitions of UDTs are modified and arrays are nested. - Fixed the issue where the return type of the
getArray()method isTYPE_OBJECTafter the data type is changed from a UDT to a UDT array. - Fixed the issue where the
getColumns()method of theDatabaseMetadatainterface cannot obtain comments when the table name contains a backtick (`) in MySQL mode. - Fixed the issue where an error is returned if a comment of a PL statement contains double slashes (
//) and is followed by a field{xxx}. - Fixed the issue where the value returned by the
getParameterCount()method called in a procedure or function is inconsistent with that in native Oracle JDBC drivers. - Fixed the issue where no error is reported for output parameters when a stored procedure is registered.
- Fixed the issue where the result set returned by the
getFunctionColumns()method is incorrect in Oracle mode. - Fixed the issue related to the precision of exported time data.
- Fixed the issue where the number of open cursors in a PL statement exceeds the limit when the PreparedStatement protocol is enabled in Oracle mode.
- Fixed the issue where ODC handles the obtained invalid dates differently from MySQL Connector/J.
- Fixed the issue where the socket is not released in a timely manner after a
SocketTimeOutexception is triggered.