Version and Copyright Information Document Title HP NonStop JDBC Type 4 Driver Programmer's Reference for SQL/MX Release 3.1 Abstract This document describes how to use the HP NonStop™ JDBC Type 4 driver 3.1. This driver provides Java applications running on a foreign platform with JDBC access to an HP NonStop SQL/MX database running on the HP NonStop platform. Where applicable, the Type 4 driver conforms to the standard JDBC 3.0 API from Oracle. Product Version HP NonStop JDBC Type 4 Driver 3.
Legal Notices © Copyright 2011 Hewlett-Packard Development Company L.P. Confidential computer software. Valid license from HP required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor’s standard commercial license. The information contained herein is subject to change without notice.
Couch, Conrad C. Huang, Ed James, Symmetric Computer Systems, Robert Elz. © 1980, 1981, 1982, 1983, 1985, 1986, 1987, 1988, 1989 Regents of the University of California.
HP NonStop JDBC Type 4 Driver 3.1 Programmer's Reference Next Version and Copyright Information Published October 2011 Table of Contents What's New in This Guide About This Guide Is This Document for You? Document Structure Printing This Document Related Reading Type 4 Driver APIs NonStop System Computing Documents Notation Conventions Abbreviations 1.
Stored Procedures Connection Pooling Statement Pooling Guidelines for Statement Pooling Troubleshooting Statement Pooling Thread-safe SQL/MX Access "Update ... Where Current of" Operations Internationalization (I18N) Support When String Literals Are Used in Applications Controlling String Literal Conversion by Using the Character-Set Properties Trimming Padding for Fixed-Length Character Columns Localizing Error Messages and Status Messages 4.
translationVerification Property url Property useArrayBinding Property useExternalTransaction Property user Property 5.
Creating LOB Tables Using SQL/MX Triggers to Delete LOB Data Backing Up and Restoring LOB Columns Limitations of LOB Data (CLOB and BLOB Data Types) 7. Module File Caching (MFC) MFC Overview Designing MFC Configuring MFC Enabling MFC MFC Usage Scenarios MFC Tunning Recommendations MFC Limitations 8.
12. Using Type 4 Driver With WebLogic Server(WLS) 8.1 WebLogic Server Overview Compatibility Supported Transaction Scenario Unsupported Transaction Scenario Connection and Statement Pooling A. Sample Programs Accessing CLOB and BLOB Data Sample Program Accessing CLOB Data Sample Program Accessing BLOB Data B. Scalar Functions Glossary Index List of Tables 1. Document Chapters 3.1. Corresponding SQL/MX Character Sets and Java Encoding Sets 4.1. Connection Control Properties 4.2.
What's New in This Guide Prev Next What's New in This Guide The following are the updates in this edition (663860-001): Added queryExecuteTime Property. Added T4QueryExecuteLogFile Property. Added useExternalTransaction Property. Added Controlling the QueryExecuteTime Logging Facility. Added QueryExecuteTime logging Message Format. Added Examples of QueryExecuteTime Logging Output. Updated Chapter 6 with new program options -bigblock. Added new messages to Chapter 11. Added new section java.sql.
About This Guide Prev Next About This Guide Is This Document for You? Document Structure Printing This Document Related Reading Type 4 Driver APIs NonStop System Computing Documents Notation Conventions Abbreviations Is This Document for You? This HP NonStop JDBC Type 4 Driver 3.1 Programmer's Reference is for experienced Java programmers who want to access NonStop SQL/MX with the Type 4 driver. This document assumes you are already familiar with: J2EE or Java applications running on JDK 1.
Logging Facilities Chapter 10, Migration and Compatibility Describes application changes needed for migration to the Type 4 driver. Chapter 11, Messages Lists messages from the Type 4 driver. The descriptions include the message-text, the cause, the effect, and recovery information. Chapter 12, Using Type 4 Driver With WebLogic Server(WLS) 8.1 Describes the use of the Type 4 Driver With WebLogic Server(WLS) 8.
JDBC Driver Reference Pages NonStop System Computing Documents The following NonStop system computing documents are available in the NonStop Technical Library at BSC. SQL/MX Connectivity Service Manual—Describes the SQL/MX connectivity service (MXCS) on the NonStop server. This product enables applications developed for the Microsoft® Open Database Connectivity (ODBC) application programming interface and other connectivity APIs to use NonStop SQL/MX to access NonStop SQL databases on NonStop systems.
print {objectID|objectName} ... An ellipsis immediately following a single syntax item indicates that you can repeat that syntax item any number of times. For example: dump objectID ... Punctuation Parentheses, commas, equal signs, and other symbols not previously described must be entered as shown. For example: -D propertyName=newValue Item Spacing Spaces shown between items are required unless one of the items is a punctuation symbol such as a parenthesis or comma.
TMF. Transaction Management Facility URL. uniform resource locator VM. virtual machine WWW. World Wide Web Prev What's New in This Guide Part Number 663860-001 Up Home Next Chapter 1.
Chapter 1. Introduction to HP NonStop JDBC Type 4 Driver Prev Next Chapter 1. Introduction to HP NonStop JDBC Type 4 Driver Type 4 Driver API Package Type 4 Driver Architecture Client Platforms Supported Accessing a Database with the Type 4 Driver Samples Type 4 Driver API Package The Type 4 driver package, com.tandem.t4jdbc , is shipped with the driver software.
Type 4 driver , through the MXCS Service, Accesses an SQL/MX Database Samples The following samples are provided with the Type 4 driver . Sample Description CallableStatementSample Demonstrates the invocation of a stored procedure in Java (SPJ).(1) DBMetaSample Gets metadata from a table by using the Connection interface and ResultSetMetaData interface.
WLS_MedRecSample NonStop SQL/MX by just reconfiguring the application in BEA WebLogic Server. No coding changes or recompilation are required to switch to NonStop SQL/MX from a different relational database management system (RDBMS).(2) WLS_TwoPhaseandPoolingSample Demonstrates that a connected pooling, particularly the number physical connections created does not exceed the maximum number of physical connections configured in BEA WebLogic Server 8.1.
Chapter 2. Installing and Verifying the Type 4 Driver Prev Next Chapter 2. Installing and Verifying the Type 4 Driver Installation Requirements Product Files Setting CLASSPATH Verifying the Type 4 Driver Installation Requirements Hardware and software requirements for the Type 4 driver are described in the Softdoc file delivered with the product, either on the product CD or on the website for Scout for NonStop Servers at HP NonStop eServices portal (https://onepoint.nonstop.compaq.com/).
Setting CLASSPATH Before running JDBC applications, ensure the CLASSPATH environment variable includes the t4sqlmx.jar file and installation directory. The t4sqlmx.jar file is located in the lib directory where you installed the product. Verifying the Type 4 Driver To verify the version of the Type 4 driver , use the command: java -jar t4sqlmx.jar This command displays an output similar to Version procedure: T1249_V31_30SEP11_HP_NONSTOP(TM)_JDBCT4_2011_...
Chapter 3. Accessing SQL Databases with SQL/MX Prev Next Chapter 3.
Data Sources JDBC Data Source (client-side) MXCS Data Source (server-side) The term data source logically refers to a database or other data storage entity. In this manual, two concepts of data source concepts apply: A JDBC (client) data source, which is physically a Java object that contains properties such as the URL of the physical database, the catalog to use when to this database, and the schema to use when to this database.
When an application requests a connection by using the getConnection method in the DataSource , the method returns a Connection object. A DataSource object is a factory for Connection objects. An object that implements the DataSource interface is typically registered with a JNDI service provider.
env.put(Context.INITIAL_CONTEXT_FACTORY, "Factory class name here"); javax.naming.Context ctx = new javax.naming.InitialContext(env); ctx.rebind("myDataSource", ds); Retrieving a DataSource Instance by using JNDI and to the Data Source Typically, the JDBC application looks up the data source JNDI name from a context object. Once the application has the DataSource object, the application does a getConnection() call on the data source and gets a connection.
Class.forName("com.tandem.t4jdbc.SQLMXDriver") Adds the Type 4 driver class to the java.lang.System property jdbc.drivers property within the application: jdbc.drivers=com.tandem.t4jdbc.SQLMXDriver Establishing the Connection The DriverManager.getConnection method accepts a string containing a Type 4 driver URL. The JDBC URL for the Type 4 driver is: jdbc:t4sqlmx://ip_address|machine_name:port_number/[:][property=value [;property2=value2 ]...
the pooled connection, and not a new physical connection. The connection pooling feature is available when the JDBC application uses either the DriverManager class or DataSource interface to obtain a JDBC connection. The connection pool size is determined by the maxPoolSize property value and minPoolSize property value. By default, connection pooling is disabled. To enable connection pooling, set the maxPoolSize property to an integer value greater than 0 (zero).
A run-time version of a table has a different redefinition timestamp than the compile-time version of the same table. An existing open operation on a table was eliminated by a DDL or SQL utility operation. The transaction isolation level and access mode at execution time is different from that at the compile time. For more information on SQL/MX recompilation, see the SQL/MX Programming Manual for C and COBOL or the SQL/MX Programming Manual for Java.
The Type 4 driver provides the following character-set mapping properties using key values as follows: Key Default Value ISO88591 ISO88591_1 KANJI SJIS KSC5601 EUC_KR A description of these character sets appears in the following table, which summarizes the character sets supported by SQL/MX. Table 3.1. Corresponding SQL/MX Character Sets and Java Encoding Sets SQL/MX Corresponding Java Character Encoding Set— Set Canonical Name for java.io and java.
exception or warning is thrown. If the translationVerification property’s value is TRUE and the driver cannot translate all or part of an SQL statement, the driver throws an SQLException with the following text: Translation of parameter to {0} failed. Cause: {1} where {0} is replaced with the target character set and {1} is replaced with the cause of the translation failure. For more information, see the translationVerification Property.
where getColumn1() returns the following stored bytes: 0x83 0x42 0x83 0x42 0x20 0x20 0x20 0x20 0x20 0x20 0x20 0x20 The driver creates a String object. String s1 = new String(outB1, “SJIS”); The resulting String object has the following UCS2 encoding: 0x30 0xA2 0x30 0xA3 0x00 0x20 0x00 0x20 0x00 0x20 0x00 0x20 0x00 0x20 0x00 0x20 0x00 0x20 0x00 0x20 The resulting string would be 10 characters (2 characters following by 8 UCS2 spaces).
Chapter 4. Type 4 Driver Properties Prev Next Chapter 4.
Client-Side Properties Server-Side Properties Type 4 driver properties that effect client-side operations and server-side are summarized in the following tables. For the detailed description, click the link provided in the property name. Note: Unless otherwise noted in the brief description, the particular property applies to the object, and ConnectionPoolDataSource object. object, DataSource DriverManager Client-Side Properties Table 4.1.
part of an SQL statement or SQL parameter. Table 4.5. Logging and Tracing Properties Property Name Description Default Value T4LogFile Sets the name of the logging file for the Type 4 driver. The name is defined by the following pattern: T4LogLevel Sets the logging levels that control logging output for the Type 4 driver. OFF %h/t4sqlmx%u.log Table 4.6. Miscellaneous Client-Side Properties Property Name Description Default Value description Specifies the registered source name.
Where To Set Properties For connections made through a DataSource or a ConnectionPoolDataSource , set the property on the DataSource or the ConnectionPoolDataSource object. For the DriverManager class, set properties in either of two ways: Using the option -Dproperty_name=property_value in the command line Using the java.util.
initialPoolSize Property ISO88591 Property KANJI Property KSC5601 Property language Property LOB Table Name Properties loginTimeout Property maxIdleTime Property maxPoolSize Property maxStatements Property minPoolSize Property networkTimeout Property password Property properties Property queryExecuteTime Property reserveDataLocators Property roundingMode Property schema Property serverDataSource Property T4LogFile Property T4LogLevel Property T4QueryExecuteLogFile Property translationVerification Property u
For example, specify the value IGNORE as follows: closeConnectionUponQueryTimeout=IGNORE connectionTimeout Property The connectionTimeout property sets the number of seconds a connection can be idle before the connection is physically closed by MXCS. Set this property on a DataSource object, ConnectionPoolDataSource object, or DriverManager object. For information about how to set properties, see How to Specify JDBC Type 4 Properties.
is set to 5 for a data source, the driver attempts to create and pool five connections the first time the application calls the data source’s getConnection() method. initialPoolSize Data type: int Units: number of physical connections Default: -1 (Do not create an initial connection pool.) Range: -1 to maxPoolSize Any negative value is treated as -1. Values can be less than minPoolSize , but must not exceed maxPoolSize .
The value can be any valid Java Canonical Name as listed in the "Canonical Name for java.io and java.lang API" column of the Oracle documentation, Supported Encodings (http://download.oracle.com/javase/1.5.0/docs/guide/intl/encoding.doc.html ). For example, to set the language to shift-JIS, Japanese: language=SJIS LOB Table Name Properties LOB tables store data for BLOB columns and CLOB columns.
connections and connections in use. When the maximum number of physical connections is reached, the Type 4 driver throws an SQLException and sends the message, Maximum pool size is reached. Set this property on a DataSource object, ConnectionPoolDataSource object, or DriverManager object. For information about how to set properties, see How to Specify JDBC Type 4 Properties. Data type: int Units: number of physical connections Default: -1 (Disables connection pooling.
networkTimeout Property The networkTimeout property sets a time limit that the driver waits for a reply from the database server. When an operation is attempted for a period longer than the set value, in seconds, the driver stops waiting for a reply and returns an SQLException to the user application. Set this property on a DataSource object, ConnectionPoolDataSource object, or DriverManager object. For information about how to set properties, see How to Specify JDBC Type 4 Properties.
LOB items, a higher value of the property can prevent frequent updating of the ZZ_DATA_LOCATOR value in the LOB table. However, if the application inserts only a small number of LOB items, a smaller value is better. If a large value is used, holes (unused data-locator numbers) could occur in the LOB table. These holes represent unused space. Also, the administrator should avoid setting high values for the reserveDataLocators (for example in the range of trillions or so).
serverDataSource=MyDataSource For more information about the default server data source, see the SQL/MX Connectivity Service Manual. T4LogFile Property The T4LogFile property sets the name of the logging file for the Type 4 driver. Set this property on a DataSource object, ConnectionPoolDataSource object, or DriverManager object. For information about how to set properties, see How to Specify JDBC Type 4 Properties. Data type: String Default file name is defined by the following pattern: %h/t4sqlmx%u.
indicates a detailed tracing message for which internal Type 4 driver methods provide messages. These messages can be useful in debugging the Type 4 driver. FINEST indicates a highly detailed tracing message. The driver provides detailed internal data messages that can be useful in debugging the Type 4 driver. ALL logs all messages. For example, to enable tracing, use the t4sqlmx.T4LogLevel property specified in the command line: -Dt4sqlmx.
the URL is: jdbc:t4sqlmx//ip_address|machine_name:port_number/[:] [property =value[; property2=value]...] where ip_address|machine_name:port_number specifies the location where the MXCS association server is running. Data type: String Default: none For example: url=jdbc:t4sqlmx://mynode.mycompanynetwork.net:18000/ url Property Considerations If the url parameter is not specified and DriverManager.getConnection() is called, the Type 4 driver throws an SQLException .
user Property The user property sets the Guardian user-name value for to MXCS. The Guardian user name passed must have adequate access permissions for SQL/MX data accessed through MXCS. Set this property on a DataSource object, ConnectionPoolDataSource object, or DriverManager object. For information about how to set properties, see How to Specify JDBC Type 4 Properties. Data type: String Default: empty string For example, user=NonStopSystem_username Prev Chapter 3.
Chapter 5. Working with BLOB and CLOB Data Prev Next Chapter 5.
Architecture for LOB Support The tables that support LOB data are: Base table Referenced by JDBC applications to insert, store, read, and update BLOB and CLOB data. In the base table, the Type 4 driver maps the BLOB and CLOB columns into a data-locator column. The data-locator column points to the actual LOB data that is stored in a separate user table called the LOB table. LOB table Actually contains the BLOB and CLOB data in chunks. A Clob or Blob object is identified by a data locator.
CLOB clobTableName For more information about using these properties, see LOB Table Name Properties. Reserving Data Locators A data locator is the reference pointer value (SQL LARGEINT data type) that is substituted for the BLOB or CLOB column in the base table definition. Each object stored into the LOB table is assigned a unique data locator value.
You can use the PreparedStatement interface to insert a CLOB column using ASCII or MBCS data. ASCII Data To insert a CLOB column using ASCII or MBCS data from an InputStream , use the PreparedStatement interface to insert the CLOB column. InputStream inputAsciiStream; PreparedStatement ps = conn.prepareStatement("insert into myTable (myClobColumn) values (?)"); ps.setAsciiStream(1, inputAsciiStream, length_of_data); ps.
Reading Unicode data from a CLOB Column To read Unicode or MBCS data from a CLOB column, use the CLOB interface or Reader . Using the CLOB interface : // Obtain the Clob from ResultSet Clob myClob = rs.getClob("myClobColumn"); // Obtain the input stream to read Clob data Reader cs = myClob.getCharacterStream(); // read Clob data using Reader char[] myClobData; myClobData = new char[length]; cs.
Use the EMPTY_BLOB() function in the insert statement to create an empty BLOB column in the database. Use setBinaryStream method of the Blob interface to obtain the InputStream to read BLOB data. Use getBinaryStream method of the Blob interface to obtain the OutputStream to write BLOB data. Use setBinaryStream of the PreparedStatement interface to write the data to the BLOB column.
To read binary data from the BLOB column, use the Blob interface or InputStream . Using the Blob interface: // Obtain the Blob from ResultSet Blob myBlob = rs.getBlob("myBlobColumn"); // Obtain the input stream to read Blob data InputStream is = myBlob.getBinaryStream(); // read Blob data using the InputStream byte[] myBlobData; myBlobData = new byte[length]; is.read(myBlobData, offset, length); Using InputStream : // obtain the InputStream from ResultSet InputStream is = rs.
You must ensure that your JDBC applications control the transactions when the BLOB columns or CLOB columns are accessed or modified. To control the transaction, set the connection to autocommit OFF mode. All LOB data access or modification is done under the application's transaction. When the autocommit mode is ON and LOB data is accessed or modified, the Type 4 driver throws the SQLException, Autocommit is on and LOB objects are involved .
Chapter 6. Managing the SQL/MX Tables for BLOB and CLOB Data Prev Next Chapter 6.
1. At the OSS prompt, invoke the SQL/MX utility MXCI. Type: mxci 2. Type the following command to enable creating tables that have LOB columns: CONTROL QUERY DEFAULT JDBC_PROCESS 'TRUE'; 3. Type the CREATE TABLE statement; for example, you might use the following simple form of the statement: CREATE TABLE table1 (c1 INTEGER NOT NULL, c2 CLOB, c3 BLOB, PRIMARY KEY(c1)); where table1 The name of the base table.
where the properties file should include the following Type 4 driver properties, as applicable: blobTableName Specifies LOB table for BLOB columns. Required if BLOB columns are involved. See LOB Table Name Properties. clobTableName Specifies the LOB table for CLOB columns. Required if CLOB columns are involved. See LOB Table Name Properties. url URL for the Type 4 driver connection. See url Property. usr User name for the Type 4 driver connection. See user Property.
is the table that contains LOB column(s). TableName> is the table that contains the LOB data. Creating LOB Tables Except as noted below, use the -create and -execute options of the Lob Admin Utility to create LOB tables. Note: Partitioned LOB tables must be manually created. You cannot use the Lob Admin Utility if your site needs partitioned LOB tables. Do not use the -execute option of the Lob Admin Utility. Follow these steps to manually create partitioned LOB tables: 1.
Note: Adding a trigger can affect up to three schemas. For each schema, you must either own the schema or be the super ID. The schema where the trigger is created. The schema where the subject table (LOB table) exists. The schema where the referenced table (base table) exists. Prev Chapter 5. Working with BLOB and CLOB Data Part Number 663860-001 Up Home Next Chapter 7.
Chapter 7. Module File Caching (MFC) Prev Next Chapter 7. Module File Caching (MFC) MFC Overview Design of MFC Configuring MFC Enabling MFC MFC Usage Scenarios MFC Tuning Recommendations MFC Limitations Statement Caching MFC Overview The applications, which use JDBC T4 driver, face repeated SQL compiles while using prepared statements. To overcome this issue, a driver side Most Frequently Used (MFU) cache is used. However, the current design of the driver side cache consumes large amount of memory.
JDBC T4 applications experiencing high memory swapping can benefit from reducing the driver side cache and enabling MFC. Reduce the driver side cache and enable MFC in the scenarios, where the MXOSRVR process exceeds 1 GB in size frequently. For JDBC T4 applications where the large number of MXOSRVR processes is configured per processor, enable MFC to reduce swapping. The other option is to increase the physical memory per processor to reduce swapping.
Chapter 8. Type 4 Driver Compliance Prev Next Chapter 8. Type 4 Driver Compliance Compliance Overview Unsupported Features Deviations HP Extensions Internationalization of Messages Conformance of DatabaseMetaData Methods' Handling of Null Parameters Type 4 Driver Conformance to SQL Data Types JDBC Data Types Floating-Point Support JDBC Type 4 Driver Features Unsupported NonStop SQL Features Unsupported SQL/MX Features Unsupported SQL/MP Features Other Unsupported Features Restrictions java.sql.connection.
PreparedStatement.setURL(int parameterIndex, URL x) The particular supported. ResultSet.getArray(int columnIndex) ResultSet.getArray(String columnName) ResultSet methods are not ResultSet.getObject(int columnIndex, Map map) ResultSet.getObject(String columnName, Map map) ResultSet.getRef(int columnIndex) ResultSet.getRef(String columnName) ResultSet.getURL(int columnIndex) ResultSet.getURL(String columnName) ResultSet.updateArray(int columnIndex) ResultSet.updateArray(String columnName) ResultSet.
java.sql.SQLOutput java.sql.Struct The following interfaces in the javax.sql package are not implemented in the Type 4 driver: Method Comments javax.sql.RowSet javax.sql.RowSetInternal RowSet javax.sql.RowSetListener javax.sql.RowSetMetaData javax.sql.RowSetReader javax.sql.RowSetWriter is not implemented in the JDBC Driver for SQL/MX. You can, however, download reference implementation of RowSet from the Oracle Web site (http://java.sun.com/developer/earlyAccess/jdbc/jdbc-rowset.html).
The result set is changed to a scrollinsensitive type. java.sql.Connection.setReadOnly(...) The read -only attribute is ignored. java.sql.ResultSet.setFetchDirection(...) The fetch direction attribute is ignored. java.sql.Statement.setEscapeProcessing(...) java.sql.Statement.setFetchDirection(...) java.sql.Statement.setQueryTimeout(int seconds ) Because SQL/MX parses the escape syntax, disabling escape processing has no effect. The fetch direction attribute is ignored.
catalog the default catalog name schemaPattern a % wildcard and retrieves data for all schemas of the specified catalog Type 4 Driver Conformance to SQL Data Types JDBC Data Types JDBC Data Types The following table shows the JDBC data types that are supported by Type 4 driver and their corresponding SQL/MX data types: JDBC Data Type Support by JDBC Type 4 Driver for NonStop SQL/MX SQL/MX Data Type Types.Array No N.A. Types.BIGINT Yes LARGEINT Types.BINARY Data type is mapped by SQL/MX .
Types.VARCHAR Yes VARCHAR(n) Types.BOOLEAN Data type is mapped by SQL/MX . Data type varies from that used for table creation. CHAR(1) Types.DATALINK No N.A. ¹ Because of mapping provided by SQL/MX, a ResultSet.getObject() method returns a string object instead of an array of bytes. The Type 4 driver maps the following data types to the JDBC data type Types.
Unsupported SQL/MX Features MXCI commands SQL/MX utility commands SQL Statements Transaction Control statements Prepared SQL statements (PREPARE and EXECUTE) Resource control and optimization statements object naming statements alias statements Refer to the NonStop SQL/MX documentation set for a complete list of supported features.
Chapter 9. Tracing and Logging Facilities Prev Next Chapter 9.
Accessing the Type 4 Driver Logging Facility The Type 4 Driver Logging facility is based on the java.util.logging package. The Type 4 driver instantiates a java.util.logging.Logger class and names the logger com.tandem.t4jdbc.logger . Your JDBC program can access the Type 4 driver logger directly by calling the java.util.logging.Logger static method getLogger(String) . For example String t4Logger = java.util.logging.Logger.getLogger(“com.tandem.t4jdbc.
Output where T4LogLevel is set to SEVERE 0000001 ~ 10/22/2004 10:22:19 ~ 001234 ~ 0049934 ~ ~ ~ ~ SQLException Operation cancelled. SQLSTATE = S1008 SQLCODE = 01118 Output where T4LogLevel is set to FINER 0000006 ~ 10/22/2004 10:34:45 ~ 001234 ~ 0049934 ~ FetchRowSetMessage ~ marshal ~ Entering FetchRowSetMessage.
Chapter 10. Migration and Compatibility Prev Next Chapter 10. Migration and Compatibility JDBC Drivers Third-Party Databases Operating Systems Compatibility JDBC Drivers Driver You Are Migrating From Code Configuration Changes Changes JDBC Type 3 Driver No Considerations url, catalog, schema, logging facilities N.A.
Chapter 11. Messages Prev Next Chapter 11. Messages About the Message Format Type 4 Driver Error Messages About the Message Format Messages are listed in numerical SQLCODE order. Descriptions include the following: SQLCODE SQLSTATE message-text Cause [ What occurred to trigger the message.] Effect [ What is the result when this occurs. ] Recovery [ How to diagnose and fix the problem. ] Type 4 Driver Error Messages 29001 HYC00 Unsupported feature - {0} Cause.
29008 24000 Invalid cursor state Cause. The ResultSet method was called when the connection was closed. Effect. The method call does not succeed. Recovery. Make sure the connection is open before making the ResultSet method call. 29009 HY109 Invalid cursor position Cause. An attempt was made to perform a deleteRow() method or updateRow() method or cancelRowUpdates method when the ResultSet row cursor was on the insert row.
Cause. A getter or setter method parameter count index is outside of the valid input-descriptor range, or the input-descriptor range is null. Effect. The getter and setter method invocation validation fails. Recovery. Change the getter or setter parameter index to a valid parameter value. 29021 HY004 Object type not supported Cause. A PreparedStatement.setObject() method call contains an unsupported Object Type. Effect. The setObject() method does not set a value for the designated parameter. Recovery.
Recovery. ASCII (ISO88591), KANJI, KSC5601, and UCS2 are the only supported character encodings. SQL/MP tables do not support UCS2 character encoding. 29037 HY106 ResultSet type is TYPE_FORWARD_ONLY Cause. An attempt was made to point a ResultSet cursor to a previous row when the object type is set as TYPE_FORWARD_ONLY . Effect. The ResultSet object cursor manipulation does not occur. Recovery. TYPE_FORWARD_ONLY ResultSet object type cursors can move forward only.
29047 HY000 Batch update failed. See next exception for details Cause. One of the commands in a batch update failed to execute properly. Effect. Not all the batch-update commands succeed. See the subsequent exception for more information. Recovery. View the subsequent exception for possible recovery actions. 29048 HY009 Invalid use of null Cause. A parameter that has an expected table name is set to null. Effect. The DatabaseMetadata method does not report any results. Recovery.
Recovery. Set the t4sqlmx.blobTableName property to a valid LOB table name. The LOB table name is of format catalog.schema.lobTableName . 29060 HY000 't4sqlmx.clobTableName' property is not set or set to null value or set to invalid value Cause. Attempted to access a CLOB column without setting the property t4sqlmx.clobTableName property, or the property is set to null value or set to an invalid value. Effect. The application cannot access CLOB columns. Recovery. Set the t4sqlmx.
Recovery. Refer to url Property for the valid address format. 29104 HY000 Expected suffix: suffix Cause. The address suffix was incorrect or missing. Effect. Operation fails. Recovery. Refer to url Property for the valid address format. 29105 HY000 Unknown prefix for address Cause. The address prefix was incorrect or missing. Effect. Operation fails. Recovery. Refer to url Property for the valid address format. 29106 HY000 Expected address format: jdbc:subprotocol::subname Cause. N.A. Effect. N.A. Recovery.
Cause. Socket write error. Effect. The operation fails. Recovery. Use the getCause method on the Exception to determine the appropriate recovery action. 29115 HY000 Error while reading from socket. Cause: cause Cause. Socket read error. Effect. The operation fails. Recovery. Use the getCause method on the Exception to determine the appropriate recovery action. 29116 HY000 Socket is closed. Cause. Socket close error. Effect. The operation fails. Recovery.
Cause. Unable to perform this operation. Effect. Operation fails. Recovery. Evaluate the returned value from the getCause method on the Exception to determine the appropriate recovery action. 29126 HY000 An execute N message error occurred. Cause: cause Cause. Unable to perform this operation. Effect. Operation fails. Recovery. Evaluate the returned value from the getCause method on the Exception to determine the appropriate recovery action. 29127 HY000 An execute rowset message error occurred.
29136 HY000 An association server connect reply occurred. Exception: exception Exception detail: exception_detail Error text/code: error text_or_code Cause. Unable to perform this operation. Effect. Operation fails. Recovery. Evaluate any error or error detail information accompanying this message. Check the EMS event log for server errors. See the Operator Messages Manual for server errors. See the SQL/MX Connectivity Service Manual for corrective action. 29137 HY000 A close reply error occurred. Cause.
Recovery. Evaluate the returned value from the getCause method on the Exception to determine the appropriate recovery action. 29147 HY000 An initialize dialogue reply error occurred. Cause. Unable to perform this operation. Effect. Operation fails. Recovery. Evaluate the returned value from the getCause method on the Exception to determine the appropriate recovery action. 29148 HY000 A prepare reply error occurred. Cause. Unable to perform this operation. Effect. Operation fails. Recovery.
29157 HY000 There was a problem reading from the server. Cause. The server reported an error. Effect. Operation fails. Recovery. Evaluate any error or error detail information accompanying the message. Check the EMS event log for server errors. See the Operator Messages Manual for server errors. See the SQL/MX Connectivity Service Manual for corrective action. 29158 HY000 The message header contained the wrong version. Expected: expected_version Actual: actual_version Cause.
29167 HY000 Internal error. An internal index failed consistency check. Cause. Internal error. Effect. Operation fails. Recovery. None. Report the entire message to your service provider. 29168 HY000 Unknown reply message error: error error detail: error_detail Cause. Server returned an error. Effect. Operation fails. Recovery. Evaluate any error or error detail information accompanying the message. Check the EMS event log for server errors. See the Operator Messages Manual for server errors.
Effect. Operation fails. Recovery. Reconnect. Set connection timeout to appropriate value. 01056 25000 Invalid transaction state. Cause. Transaction state is incorrect. Effect. Operation fails. Recovery. Retry. 01118 S1008 Operation cancelled. Cause. The operation was cancelled. Effect. Operation fails. Recovery. Retry operation. 08001 HY000 Retry attempts to connect to the datasource failed, May be ODBC server not able to register to the ODBC service process. Cause. A server error. Effect. Operation fails.
29186 HY000 Internal error occurred while getting the SQLMXXAConnection object.- {0} Cause. Internal error. Effect. Operation fails. Recovery. None. Report the entire message to your service provider. 29187 HY000 Internal error occurred while getting the SQLMXXAResource object. - {0} Cause. Internal error. Effect. Operation fails. Recovery. None. Report the entire message to your service provider. 29188 HY000 Invalid Tx connection. Connection closed.- {0} Cause.
ERROR (closeConnectionUponQueryTimeout Enabled). Cause. The long running query timed out after specified number of seconds. Effect. The MXOSRVR on NSK did not stop successfully. Recovery. None. The corresponding MXOSRVR is in use by another client. 29196 HY000 SQL Server and connection could not be aborted successfully, SERVER STOP ERROR (closeConnectionUponQueryTimeout Enabled). Cause. The long running query timed out after specified number of seconds. Effect. The MXOSRVR on NSK did not stop successfully.
Chapter 12. Using Type 4 Driver With WebLogic Server(WLS) 8.1 Prev Next Chapter 12. Using Type 4 Driver With WebLogic Server(WLS) 8.
BEA WLS 8.1 Unsupported Transaction Scenario Connection and Statement Pooling The Type 4 driver supports all interfaces required for WLS 8.1 connection pooling and statement pooling. A WLS 8.
with the Type 4 driver product for demonstrating connection pooling and integration. WLS8.1 implements the connection pooling component. The WLS8.1 application server maintains the cache of pooled objects, and retrieves an object when the client requests a connection. When the application is finished using the connection object, that object is returned to the pool and made available for future requests. If the connection cannot be initialized, the pooling component discards the pooled connection object.
Appendix A. Sample Programs Accessing CLOB and BLOB Data Prev Next Appendix A. Sample Programs Accessing CLOB and BLOB Data Sample Program Accessing CLOB Data Sample Program Accessing BLOB Data This appendix shows two working programs. Sample Program Accessing CLOB Data This sample program shows operations that can be performed through the Clob interface or through the PreparedStatement interface.
+ length + " of file " + args[1]); try { Class.forName("com.tandem.t4jdbc.SQLMXDriver"); start = System.currentTimeMillis(); //url should be of the form: // jdbc:t4sqlmx://ip_address|machine_name:port_number/:” String url = “jdbc:t4sqlmx://mymachine:6000/:”; conn1 = DriverManager.getConnection(url); System.out.println("Cleaning up test tables..."); Statement stmt0 = conn1.createStatement(); stmt0.execute("delete from clobdatatbl"); stmt0.execute("delete from clobbase"); conn1.
// >> create table blobtiff // (col1 int not null not droppable, // tiff blob, primary key (col1)); // // The LOB table for this example is created through the // T4LobAdmin utility as: // >> create table cat.sch.
stmt1.setBinaryStream(2,iXstream,numBytes); stmt1.executeUpdate(); conn1.commit(); } catch (SQLException e) { e.printStackTrace(); SQLException next = e; do { System.out.println("Messge : " + e.getMessage()); System.out.println("Error Code : " + e.getErrorCode()); System.out.println("SQLState : " + e.getSQLState()); } while ((next = next.
Appendix B. Scalar Functions Prev Next Appendix B.
Glossary Prev Next Glossary A |B |C |D |E |F |G |H |I |J |K |L |M |N |O |P |Q |R |S |T |U |V |W |X |Y |Z A abstract class In Java, a class designed only as a parent from which subclasses can be derived, which is not itself suitable for instantiation. An abstract class is often used to "abstract out" incomplete sets of features, which can then be shared by a group of sibling subclasses that add different variations of the missing pieces.
partitions. class path The location where the Java VM and other Java programs that are located in the directory search for class libraries (such as classes.zip ). Include the t4sqlmx.jar file in your class path. The t4sqlmx.jar file is in the location where you installed this product. You can set the class path explicitly or with the CLASSPATH environment variable. client A software process, hardware device, or combination of the two that requests services from a server.
exceptions using the throw keyword and handle exceptions using try , catch , and finally blocks. Expand The NonStop Kernel operating system network that extends the concept of fault tolerance to networks of geographically distributed NonStop systems. If the network is properly designed, communication paths are constantly available even if there is a single line failure or component failure. expandability See scalability.
Hypertext Markup Language (HTML) A hypertext document format used on the World Wide Web. Hypertext Transfer Protocol (HTTP) The client-server Transmission Control Protocol/Internet Protocol (TCP/IP) used on the World Wide Web for the exchange of HTML documents. I IEC See International Electrotechnical Commission (IEC). IEEE Institute for Electrical and Electronic Engineers (IEEE). interactive Question-and-answer exchange between a user and a computer system.
(http://download.oracle.com/javase/1.5.0/docs/index.html ). Java Foundation Classes See Core API. Java HotSpot virtual machine The Java virtual machine implementation designed to produce maximum program-execution speed for applications running in a server environment. The Java HotSpot virtual machine is a run-time environment that features an adaptive compiler that dynamically optimizes the performance of running applications. NonStop Server for Java 4 implements the Java HotSpot virtual machine.
The HP NonStop SQL/MX Connectivity Service. This product enables applications developed for the JDBC application programming interface and other connectivity APIs to use HP NonStop SQL/MX to access HP NonStop SQL databases on an HP NonStop system. MXCS Association Server The HP NonStop MXCS component that starts and manages MXCS SQL servers and associates a client connection request with a specific MXCS SQL server in a data source.
formatting, including the syntax of messages, the terminal-to-computer dialogue, character sets, sequencing of messages, and so on. Q There are no entries for this section. R RDF See Remote Duplicate Database Facility (RDF).
A task that is separately dispatched and that represents a sequential flow of control within a process. threads The nonnative thread package that is shipped with Oracle JDK. throw Java keyword used to raise an exception. throws Java keyword used to define the exceptions that a method can raise. TMF See HP NonStop Transaction Management Facility (TMF) transaction A user-defined action that a client program (usually running on a workstation) requests from a server.
Part Number 663860-001 Legal Notices
Index Prev Index A Abbreviations in this manual, Abbreviations Access considerations Blob and Clob objects, Access Considerations for Clob and Blob Objects API, Communication Overview (see also Java API) layer, Communication Overview Appendix A, Sample Programs Accessing CLOB and BLOB Data Appendix B, Scalar Functions Architecture LOB support, Architecture for LOB Support Type 4 driver, Type 4 Driver Architecture ASCII data PreparedStatement interface, ASCII Data reading, Reading ASCII Data from a CLOB Col
transactions, Transactions Involving Blob and Clob Access writing binary data to, Writing Binary Data to a BLOB Column BLOB data accessing sample program, Sample Program Accessing BLOB Data data type limitations, Limitations of LOB Data (CLOB and BLOB Data Types) deleting, Deleting BLOB Data properties for, Client-Side Properties storing, Storing BLOB Data updating, Updating BLOB Data working with, Working with BLOB and CLOB Data Blob interface inserting, Inserting a BLOB Column by Using the Blob Interface
data type limitations, Limitations of LOB Data (CLOB and BLOB Data Types) deleting, Deleting CLOB Data inserting using PreparedStatement interface, Inserting CLOB Data by Using the PreparedStatement Interface properties for, Client-Side Properties reading, Reading CLOB Data storing, Storing CLOB Data updating, Updating CLOB Data working with, Working with BLOB and CLOB Data Clob interface inserting CLOB columns, Inserting CLOB Columns by Using the Clob Interface writing ASCII or MBCS data, ASCII Data Clob o
loginTimeout property, loginTimeout Property maxIdleTime property, maxIdleTime Property connectionTimeout property, connectionTimeout Property Connection and Statement Pooling, Connection and Statement Pooling create option, program_options CREATE TABLE statement base tables, Using MXCI To Create Base Tables that Have LOB Columns Creating base tables, Creating Base Tables that Have LOB Columns data source, Programmatically Creating an Instance of the DataSource Class LOB tables, Creating LOB Tables localize
DELETE statement BLOB data, Deleting BLOB Data CLOB data, Deleting CLOB Data Deleting BLOB data, Deleting BLOB Data CLOB data, Deleting CLOB Data LOB data, Using SQL/MX Triggers to Delete LOB Data description property, description Property Document printing, Printing This Document structure, Document Structure Documents NonStop computing manuals, NonStop System Computing Documents related reading, Related Reading SQL/MX, NonStop System Computing Documents Driver class, Loading and Registering the Driver Dri
Features, What's New in This Guide Fetch size, "Update ...
encoding sets, Controlling String Literal Conversion by Using the Character-Set Properties JDK version, Installation Requirements java command-line, Setting Properties in the Command Line Java API prerequisite, Is This Document for You? Java Naming and Directory Interface, Connection by Using the DataSource Interface JDBC data types, JDBC Data Types drivers, migrating, JDBC Drivers tutorial, Overview of Tasks to Deploy DataSource Objects URL, Establishing the Connection JDBC 3.
LOB columns (see also BLOB columns) backing up, Backing Up and Restoring LOB Columns data types, Data Types for LOB Columns LOB data limitations, Limitations of LOB Data (CLOB and BLOB Data Types) LOB support architecture, Architecture for LOB Support LOB table name properties, LOB Table Name Properties reserveDataLocators property, reserveDataLocators Property LOB tables creating, Creating LOB Tables illustrated, Architecture for LOB Support limitation on partitioning, Creating LOB Tables partitioning, Cre
Message format, logging output, Message Format Messages creating localized file, Procedure To Create a Localized-Message File internationalization of, Internationalization of Messages language property, language Property localized file, File-Name Format for the Localized-Messages File localizing, Localizing Error Messages and Status Messages Type 4 driver, Messages Migration, Migration minPoolSize property, minPoolSize Property Module File Caching configuration of, Configuring MFC design of, Designing MFC l
(see also Connection pooling) enabling, maxPoolSize Property management properties, Client-Side Properties Precedence property specifications, Precedence of Property Specifications PreparedStatement interface inserting a Blob, Inserting a BLOB Column by Using the PreparedStatement Interface inserting CLOB data, Inserting CLOB Data by Using the PreparedStatement Interface statement pooling, Statement Pooling Prerequisites, Is This Document for You? Primary key base tables, Using MXCI To Create Base Tables th
LOB columns, Backing Up and Restoring LOB Columns Restrictions, Restrictions ResultSet interface fetch size, "Update ...
SQL data types, Type 4 Driver Conformance to SQL Data Types SQL Link JDBC driver, JDBC Drivers SQLMXMessages_en.
Blob and Clob access, Transactions Involving Blob and Clob Access translationVerification property description, translationVerification Property Transport layer, Communication Overview trigger option, program_options Triggers deleting LOB data, Using SQL/MX Triggers to Delete LOB Data generating SQL statements, program_options Trimming padding, Trimming Padding for Fixed-Length Character Columns Troubleshooting fixed-length character column inserts, How the Padding Character Causes the Discrepancy in Length
precedence, Precedence of Property Specifications server-side, Server-Side Properties setting, Where To Set Properties setting for LOB tables, Setting Properties for the LOB Table specifying, How to Specify JDBC Type 4 Properties U UCS2 character set, How the Padding Character Causes the Discrepancy in Length Unsupported features other, Other Unsupported Features SQL/MP, Unsupported SQL/MP Features SQL/MX, Unsupported NonStop SQL Features Unicode insert, Inserting a CLOB column with Unicode data using a Re
product CD, Product Files related reading, Related Reading Writer current object, Access Considerations for Clob and Blob Objects Writing ASCII data, Writing ASCII or MBCS Data to a CLOB Column Binary data, Writing Binary Data to a BLOB Column MBCS data, Writing ASCII or MBCS Data to a CLOB Column Prev Glossary Part Number 663860-001 Up Home Legal Notices