JDBC Driver for SQL/MX Programmer's Reference
Batch Updates
The batch update facility allows a Statement object to submit a set of heterogeneous update, insert, or delete commands together as a
single unit to the database. This facility also allows multiple sets of parameters to be associated with a PreparedStatement object.
When the autocommit mode is enabled, the JDBC Driver for SQL/MX commits the updates only when all commands in the batch succeed.
If any command in the batch fails, the updates are rolled back in both autocommit and nonautocommit mode.
HP Extensions
The following HP extensions to the JDBC standard are implemented in the JDBC Driver for SQL/MX.
Interval Data Type
The interval data type is not a generic SQL type defined in the Java 2 JDBC 3.0 Specification, but SQL/MX supports the interval
data type. To allow JDBC applications for SQL/MX to access the interval data type, the JDBC Driver for SQL/MX maps it to the
Types.OTHER data type. The JDBC Driver for SQL/MX enables the getObject() and getString() methods of the ResultSet
interface, and the setObject() and setString() methods of the PreparedStatement interface, to access this data type. The
interval data type is always accessed as a String object. The JDBC Driver for SQL/MX also allows escape syntax for interval
literals.
Internationalization
The JDBC Driver for SQL/MX is designed so that Java messages can be adopted for various languages. The error messages in JDBC/MX
components are stored outside the source code in a separate property file and retrieved dynamically based on the locale setting. The error
messages in different languages are stored in separate property files based on the language and country. This extension does not apply to all
messages that can occur when running JDBC applications.
SQL Conformance
JDBC/MX conforms to the SQL language entry level of SQL:1999. This subsection describes the JDBC/MX support for:
SQL Scalar Functions●
CONVERT Function●
JDBC Data Types●
SQL Escape Clauses●
SQL Scalar Functions
JDBC/MX maps JDBC scalar functions to their equivalent SQL/MX functions, as shown in the following tables:
Numeric Functions
JDBC Function SQL/MX Equivalent Function
ABS ABS
ACOS ACOS
ASIN ASIN
ATAN ATAN
ATAN2 ATAN2
CEILING CEILING
COS COS
COT
Not supported in this release