You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafodion.apache.org by db...@apache.org on 2016/05/02 18:12:15 UTC
[36/60] incubator-trafodion git commit: TRAFODION-1933 JDBC TYpe4
driver build scripts migrated to use maven instead of ant
TRAFODION-1933 JDBC TYpe4 driver build scripts migrated to use maven instead of ant
Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/72e17019
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/72e17019
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/72e17019
Branch: refs/heads/master
Commit: 72e170198fa80baa9891fc40fc7b66da8cbb6a32
Parents: b7ecf18
Author: Anuradha Hegde <an...@esgyn.com>
Authored: Mon Apr 18 16:11:06 2016 +0000
Committer: Anuradha Hegde <an...@esgyn.com>
Committed: Mon Apr 18 16:11:06 2016 +0000
----------------------------------------------------------------------
core/Makefile | 9 +-
.../jdbcT4/src/main/java/T4Messages.properties | 686 ++
.../java/org/trafodion/jdbc/t4/Address.java | 117 +
.../java/org/trafodion/jdbc/t4/BaseRow.java | 65 +
.../main/java/org/trafodion/jdbc/t4/Bytes.java | 269 +
.../jdbc/t4/CONNECTION_CONTEXT_def.java | 149 +
.../jdbc/t4/CachedPreparedStatement.java | 67 +
.../org/trafodion/jdbc/t4/CancelMessage.java | 49 +
.../java/org/trafodion/jdbc/t4/CancelReply.java | 38 +
.../java/org/trafodion/jdbc/t4/Certificate.java | 112 +
.../main/java/org/trafodion/jdbc/t4/Cipher.java | 201 +
.../org/trafodion/jdbc/t4/CloseMessage.java | 48 +
.../java/org/trafodion/jdbc/t4/CloseReply.java | 48 +
.../java/org/trafodion/jdbc/t4/Compression.java | 149 +
.../org/trafodion/jdbc/t4/ConnectMessage.java | 62 +
.../org/trafodion/jdbc/t4/ConnectReply.java | 148 +
.../java/org/trafodion/jdbc/t4/Descriptor2.java | 85 +
.../trafodion/jdbc/t4/ERROR_DESC_LIST_def.java | 42 +
.../org/trafodion/jdbc/t4/ERROR_DESC_def.java | 65 +
.../jdbc/t4/EndTransactionMessage.java | 49 +
.../trafodion/jdbc/t4/EndTransactionReply.java | 49 +
.../org/trafodion/jdbc/t4/ExecuteMessage.java | 107 +
.../org/trafodion/jdbc/t4/ExecuteReply.java | 127 +
.../org/trafodion/jdbc/t4/FetchMessage.java | 63 +
.../java/org/trafodion/jdbc/t4/FetchReply.java | 63 +
.../org/trafodion/jdbc/t4/GenericMessage.java | 45 +
.../org/trafodion/jdbc/t4/GenericReply.java | 43 +
.../jdbc/t4/GetSQLCatalogsMessage.java | 88 +
.../trafodion/jdbc/t4/GetSQLCatalogsReply.java | 54 +
.../jdbc/t4/HPT4ConnectionPoolDataSource.java | 346 +
.../t4/HPT4ConnectionPoolDataSourceFactory.java | 68 +
.../org/trafodion/jdbc/t4/HPT4DataSource.java | 366 ++
.../jdbc/t4/HPT4DataSourceFactory.java | 62 +
.../java/org/trafodion/jdbc/t4/HPT4Desc.java | 542 ++
.../org/trafodion/jdbc/t4/HPT4Exception.java | 38 +
.../java/org/trafodion/jdbc/t4/HPT4Handle.java | 84 +
.../org/trafodion/jdbc/t4/HPT4Messages.java | 324 +
.../jdbc/t4/HPT4ParameterMetaData.java | 243 +
.../trafodion/jdbc/t4/HPT4PooledConnection.java | 238 +
.../jdbc/t4/HPT4PooledConnectionManager.java | 385 ++
.../jdbc/t4/HPT4ResultSetMetaData.java | 309 +
.../main/java/org/trafodion/jdbc/t4/Header.java | 157 +
.../jdbc/t4/InitializeDialogueMessage.java | 66 +
.../jdbc/t4/InitializeDialogueReply.java | 90 +
.../java/org/trafodion/jdbc/t4/InputOutput.java | 682 ++
.../java/org/trafodion/jdbc/t4/InsertRow.java | 82 +
.../trafodion/jdbc/t4/InterfaceConnection.java | 1420 +++++
.../trafodion/jdbc/t4/InterfaceResultSet.java | 927 +++
.../trafodion/jdbc/t4/InterfaceStatement.java | 1392 +++++
.../trafodion/jdbc/t4/InterfaceUtilities.java | 235 +
.../main/java/org/trafodion/jdbc/t4/Key.java | 161 +
.../org/trafodion/jdbc/t4/LogicalByteArray.java | 345 +
.../org/trafodion/jdbc/t4/MessageDigest.java | 84 +
.../java/org/trafodion/jdbc/t4/NCSAddress.java | 220 +
.../jdbc/t4/OUT_CONNECTION_CONTEXT_def.java | 97 +
.../org/trafodion/jdbc/t4/PrepareMessage.java | 82 +
.../org/trafodion/jdbc/t4/PrepareReply.java | 103 +
.../jdbc/t4/PreparedStatementManager.java | 242 +
.../main/java/org/trafodion/jdbc/t4/Row.java | 233 +
.../trafodion/jdbc/t4/SQLItemDescList_def.java | 46 +
.../trafodion/jdbc/t4/SQLItemDescOld_def.java | 54 +
.../org/trafodion/jdbc/t4/SQLItemDesc_def.java | 70 +
.../org/trafodion/jdbc/t4/SQLValueList_def.java | 64 +
.../org/trafodion/jdbc/t4/SQLValue_def.java | 55 +
.../trafodion/jdbc/t4/SQLWarningOrError.java | 47 +
.../trafodion/jdbc/t4/SQL_DataValue_def.java | 54 +
.../org/trafodion/jdbc/t4/SecClientMsgKeys.java | 58 +
.../main/java/org/trafodion/jdbc/t4/SecPwd.java | 274 +
.../trafodion/jdbc/t4/SecResourceBundle.java | 57 +
.../org/trafodion/jdbc/t4/SecdefsCommon.java | 84 +
.../java/org/trafodion/jdbc/t4/Security.java | 319 +
.../trafodion/jdbc/t4/SecurityException.java | 47 +
.../jdbc/t4/SetConnectionOptionMessage.java | 50 +
.../jdbc/t4/SetConnectionOptionReply.java | 45 +
.../java/org/trafodion/jdbc/t4/SymCrypto.java | 87 +
.../java/org/trafodion/jdbc/t4/T4Address.java | 315 +
.../org/trafodion/jdbc/t4/T4Connection.java | 505 ++
.../org/trafodion/jdbc/t4/T4DSProperties.java | 967 +++
.../trafodion/jdbc/t4/T4DatabaseMetaData.java | 5901 ++++++++++++++++++
.../java/org/trafodion/jdbc/t4/T4Driver.java | 367 ++
.../org/trafodion/jdbc/t4/T4LogFormatter.java | 236 +
.../trafodion/jdbc/t4/T4LoggingUtilities.java | 816 +++
.../org/trafodion/jdbc/t4/T4Properties.java | 2511 ++++++++
.../java/org/trafodion/jdbc/t4/T4ResultSet.java | 164 +
.../java/org/trafodion/jdbc/t4/T4Statement.java | 204 +
.../org/trafodion/jdbc/t4/T4TimerThread.java | 116 +
.../org/trafodion/jdbc/t4/T4_Dcs_Cancel.java | 115 +
.../org/trafodion/jdbc/t4/T4_Dcs_Connect.java | 123 +
.../java/org/trafodion/jdbc/t4/TRANSPORT.java | 263 +
.../jdbc/t4/TerminateDialogueMessage.java | 38 +
.../jdbc/t4/TerminateDialogueReply.java | 39 +
.../jdbc/t4/TrafT4CallableStatement.java | 2462 ++++++++
.../org/trafodion/jdbc/t4/TrafT4Connection.java | 1987 ++++++
.../jdbc/t4/TrafT4PreparedStatement.java | 2558 ++++++++
.../org/trafodion/jdbc/t4/TrafT4ResultSet.java | 5389 ++++++++++++++++
.../org/trafodion/jdbc/t4/TrafT4Statement.java | 1690 +++++
.../org/trafodion/jdbc/t4/USER_DESC_def.java | 61 +
.../java/org/trafodion/jdbc/t4/Utility.java | 636 ++
.../org/trafodion/jdbc/t4/VERSION_LIST_def.java | 65 +
.../java/org/trafodion/jdbc/t4/VERSION_def.java | 61 +
.../java/org/trafodion/jdbc/t4/Vproc.java-tmpl | 36 +
.../jdbc/t4/odbc_Dcs_GetObjRefHdl_exc_.java | 95 +
.../jdbc/t4/odbc_Dcs_StopSrvr_exc_.java | 86 +
.../jdbc/t4/odbc_SQLSvc_Close_exc_.java | 69 +
.../t4/odbc_SQLSvc_EndTransaction_exc_.java | 87 +
.../jdbc/t4/odbc_SQLSvc_Execute_exc_.java | 89 +
.../jdbc/t4/odbc_SQLSvc_Fetch_exc_.java | 87 +
.../t4/odbc_SQLSvc_GetSQLCatalogs_exc_.java | 100 +
.../t4/odbc_SQLSvc_InitializeDialogue_exc_.java | 76 +
.../jdbc/t4/odbc_SQLSvc_Prepare_exc_.java | 68 +
.../odbc_SQLSvc_SetConnectionOption_exc_.java | 70 +
.../t4/odbc_SQLSvc_TerminateDialogue_exc_.java | 66 +
.../jdbcT4/src/main/java/secClient.properties | 53 +
.../CallableStatementSample.java | 83 -
.../CallableStatementSample/IntegerSPJ.java | 28 -
.../samples/CallableStatementSample/README | 42 -
.../samples/DBMetaSample/DBMetaSample.java | 132 -
.../conn/jdbc_type4/samples/DBMetaSample/README | 904 ---
.../PreparedStatementSample.java | 151 -
.../samples/PreparedStatementSample/README | 232 -
core/conn/jdbc_type4/samples/README | 47 -
.../jdbc_type4/samples/ResultSetSample/README | 91 -
.../ResultSetSample/ResultSetSample.java | 104 -
.../jdbc_type4/samples/StatementSample/README | 92 -
.../StatementSample/StatementSample.java | 104 -
core/conn/jdbc_type4/samples/build.xml | 44 -
.../jdbc_type4/samples/common/sampleUtils.java | 268 -
core/conn/jdbc_type4/samples/t4jdbc.properties | 26 -
core/conn/jdbc_type4/src/T4Messages.properties | 686 --
.../src/org/trafodion/jdbc/t4/Address.java | 117 -
.../src/org/trafodion/jdbc/t4/BaseRow.java | 65 -
.../src/org/trafodion/jdbc/t4/Bytes.java | 269 -
.../jdbc/t4/CONNECTION_CONTEXT_def.java | 149 -
.../jdbc/t4/CachedPreparedStatement.java | 67 -
.../org/trafodion/jdbc/t4/CancelMessage.java | 49 -
.../src/org/trafodion/jdbc/t4/CancelReply.java | 38 -
.../src/org/trafodion/jdbc/t4/Certificate.java | 112 -
.../src/org/trafodion/jdbc/t4/Cipher.java | 201 -
.../src/org/trafodion/jdbc/t4/CloseMessage.java | 48 -
.../src/org/trafodion/jdbc/t4/CloseReply.java | 48 -
.../src/org/trafodion/jdbc/t4/Compression.java | 149 -
.../org/trafodion/jdbc/t4/ConnectMessage.java | 62 -
.../src/org/trafodion/jdbc/t4/ConnectReply.java | 148 -
.../src/org/trafodion/jdbc/t4/Descriptor2.java | 85 -
.../trafodion/jdbc/t4/ERROR_DESC_LIST_def.java | 42 -
.../org/trafodion/jdbc/t4/ERROR_DESC_def.java | 65 -
.../jdbc/t4/EndTransactionMessage.java | 49 -
.../trafodion/jdbc/t4/EndTransactionReply.java | 49 -
.../org/trafodion/jdbc/t4/ExecuteMessage.java | 107 -
.../src/org/trafodion/jdbc/t4/ExecuteReply.java | 127 -
.../src/org/trafodion/jdbc/t4/FetchMessage.java | 63 -
.../src/org/trafodion/jdbc/t4/FetchReply.java | 63 -
.../org/trafodion/jdbc/t4/GenericMessage.java | 45 -
.../src/org/trafodion/jdbc/t4/GenericReply.java | 43 -
.../jdbc/t4/GetSQLCatalogsMessage.java | 88 -
.../trafodion/jdbc/t4/GetSQLCatalogsReply.java | 54 -
.../jdbc/t4/HPT4ConnectionPoolDataSource.java | 346 -
.../t4/HPT4ConnectionPoolDataSourceFactory.java | 68 -
.../org/trafodion/jdbc/t4/HPT4DataSource.java | 366 --
.../jdbc/t4/HPT4DataSourceFactory.java | 62 -
.../src/org/trafodion/jdbc/t4/HPT4Desc.java | 542 --
.../org/trafodion/jdbc/t4/HPT4Exception.java | 38 -
.../src/org/trafodion/jdbc/t4/HPT4Handle.java | 84 -
.../src/org/trafodion/jdbc/t4/HPT4Messages.java | 324 -
.../jdbc/t4/HPT4ParameterMetaData.java | 243 -
.../trafodion/jdbc/t4/HPT4PooledConnection.java | 238 -
.../jdbc/t4/HPT4PooledConnectionManager.java | 385 --
.../jdbc/t4/HPT4ResultSetMetaData.java | 309 -
.../src/org/trafodion/jdbc/t4/Header.java | 157 -
.../jdbc/t4/InitializeDialogueMessage.java | 66 -
.../jdbc/t4/InitializeDialogueReply.java | 90 -
.../src/org/trafodion/jdbc/t4/InputOutput.java | 682 --
.../src/org/trafodion/jdbc/t4/InsertRow.java | 82 -
.../trafodion/jdbc/t4/InterfaceConnection.java | 1420 -----
.../trafodion/jdbc/t4/InterfaceResultSet.java | 927 ---
.../trafodion/jdbc/t4/InterfaceStatement.java | 1392 -----
.../trafodion/jdbc/t4/InterfaceUtilities.java | 235 -
.../src/org/trafodion/jdbc/t4/Key.java | 161 -
.../org/trafodion/jdbc/t4/LogicalByteArray.java | 345 -
.../org/trafodion/jdbc/t4/MessageDigest.java | 84 -
.../src/org/trafodion/jdbc/t4/NCSAddress.java | 220 -
.../jdbc/t4/OUT_CONNECTION_CONTEXT_def.java | 97 -
.../org/trafodion/jdbc/t4/PrepareMessage.java | 82 -
.../src/org/trafodion/jdbc/t4/PrepareReply.java | 103 -
.../jdbc/t4/PreparedStatementManager.java | 242 -
.../src/org/trafodion/jdbc/t4/Row.java | 233 -
.../trafodion/jdbc/t4/SQLItemDescList_def.java | 46 -
.../trafodion/jdbc/t4/SQLItemDescOld_def.java | 54 -
.../org/trafodion/jdbc/t4/SQLItemDesc_def.java | 70 -
.../org/trafodion/jdbc/t4/SQLValueList_def.java | 64 -
.../src/org/trafodion/jdbc/t4/SQLValue_def.java | 55 -
.../trafodion/jdbc/t4/SQLWarningOrError.java | 47 -
.../trafodion/jdbc/t4/SQL_DataValue_def.java | 54 -
.../org/trafodion/jdbc/t4/SecClientMsgKeys.java | 58 -
.../src/org/trafodion/jdbc/t4/SecPwd.java | 274 -
.../trafodion/jdbc/t4/SecResourceBundle.java | 57 -
.../org/trafodion/jdbc/t4/SecdefsCommon.java | 84 -
.../src/org/trafodion/jdbc/t4/Security.java | 319 -
.../trafodion/jdbc/t4/SecurityException.java | 47 -
.../jdbc/t4/SetConnectionOptionMessage.java | 50 -
.../jdbc/t4/SetConnectionOptionReply.java | 45 -
.../src/org/trafodion/jdbc/t4/SymCrypto.java | 87 -
.../src/org/trafodion/jdbc/t4/T4Address.java | 315 -
.../src/org/trafodion/jdbc/t4/T4Connection.java | 505 --
.../org/trafodion/jdbc/t4/T4DSProperties.java | 967 ---
.../trafodion/jdbc/t4/T4DatabaseMetaData.java | 5901 ------------------
.../src/org/trafodion/jdbc/t4/T4Driver.java | 367 --
.../org/trafodion/jdbc/t4/T4LogFormatter.java | 236 -
.../trafodion/jdbc/t4/T4LoggingUtilities.java | 816 ---
.../src/org/trafodion/jdbc/t4/T4Properties.java | 2511 --------
.../src/org/trafodion/jdbc/t4/T4ResultSet.java | 164 -
.../src/org/trafodion/jdbc/t4/T4Statement.java | 204 -
.../org/trafodion/jdbc/t4/T4TimerThread.java | 116 -
.../org/trafodion/jdbc/t4/T4_Dcs_Cancel.java | 115 -
.../org/trafodion/jdbc/t4/T4_Dcs_Connect.java | 123 -
.../src/org/trafodion/jdbc/t4/TRANSPORT.java | 263 -
.../jdbc/t4/TerminateDialogueMessage.java | 38 -
.../jdbc/t4/TerminateDialogueReply.java | 39 -
.../jdbc/t4/TrafT4CallableStatement.java | 2462 --------
.../org/trafodion/jdbc/t4/TrafT4Connection.java | 1987 ------
.../jdbc/t4/TrafT4PreparedStatement.java | 2558 --------
.../org/trafodion/jdbc/t4/TrafT4ResultSet.java | 5389 ----------------
.../org/trafodion/jdbc/t4/TrafT4Statement.java | 1690 -----
.../org/trafodion/jdbc/t4/USER_DESC_def.java | 61 -
.../src/org/trafodion/jdbc/t4/Utility.java | 636 --
.../org/trafodion/jdbc/t4/VERSION_LIST_def.java | 65 -
.../src/org/trafodion/jdbc/t4/VERSION_def.java | 61 -
.../src/org/trafodion/jdbc/t4/Vproc.java | 36 -
.../jdbc/t4/odbc_Dcs_GetObjRefHdl_exc_.java | 95 -
.../jdbc/t4/odbc_Dcs_StopSrvr_exc_.java | 86 -
.../jdbc/t4/odbc_SQLSvc_Close_exc_.java | 69 -
.../t4/odbc_SQLSvc_EndTransaction_exc_.java | 87 -
.../jdbc/t4/odbc_SQLSvc_Execute_exc_.java | 89 -
.../jdbc/t4/odbc_SQLSvc_Fetch_exc_.java | 87 -
.../t4/odbc_SQLSvc_GetSQLCatalogs_exc_.java | 100 -
.../t4/odbc_SQLSvc_InitializeDialogue_exc_.java | 76 -
.../jdbc/t4/odbc_SQLSvc_Prepare_exc_.java | 68 -
.../odbc_SQLSvc_SetConnectionOption_exc_.java | 70 -
.../t4/odbc_SQLSvc_TerminateDialogue_exc_.java | 66 -
core/conn/jdbc_type4/src/secClient.properties | 53 -
core/conn/trafci/install/Installer.java | 2 +-
241 files changed, 42697 insertions(+), 45048 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/Makefile
----------------------------------------------------------------------
diff --git a/core/Makefile b/core/Makefile
index 99fdd5e..6c4b865 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -68,10 +68,7 @@ foundation: sqroot dbsecurity $(MPI_TARGET) $(SEAMONSTER_TARGET)
cd sqf && $(MAKE) all
jdbc_jar: verhdr
- cd conn/jdbc_type4 && $(ANT) deploy 2>&1 | sed -e "s/$$/ ##(JDBCT4)/";exit $${PIPESTATUS[0]}
- $(MAVEN) install:install-file -Dfile=conn/jdbc_type4/lib/jdbcT4.jar \
- -DgroupId=org.trafodion.jdbc.t4.T4Driver -DartifactId=t4driver -Dversion="$$TRAFODION_VER" \
- -Dpackaging=jar -DgeneratePom=true | sed -e "s/$$/ ##(JDBCT4)/";exit $${PIPESTATUS[0]}
+ cd conn/jdbcT4 && $(MAKE) 2>&1 && $(MAVEN) install | sed -e "s/$$/ ##(JDBCT4)/";exit $${PIPESTATUS[0]}
dcs: jdbc_jar jdbc_type2_jar
cd ../dcs && $(MAKE) 2>&1 | sed -e "s/$$/ ##(DCS)/" ; exit $${PIPESTATUS[0]}
@@ -109,7 +106,7 @@ clean: sqroot
cd sqf && $(MAKE) clean
cd conn/odbc/src/odbc && $(MAKE) clean
cd conn/trafci && $(ANT) clean
- cd conn/jdbc_type4 && $(ANT) clean
+ cd conn/jdbcT4 && $(MAKE) clean
cd conn && $(MAKE) clean
cd conn/jdbc_type2 && $(ANT) clean && $(MAKE) clean
cd rest && $(MAKE) clean
@@ -123,7 +120,7 @@ cleanall: sqroot eclipseclean cleantests
cd sqf && $(MAKE) cleanall
cd conn/odbc/src/odbc && $(MAKE) cleanall
cd conn/trafci && $(ANT) clean
- cd conn/jdbc_type4 && $(ANT) clean
+ cd conn/jdbcT4 && $(MAKE) clean
cd conn && $(MAKE) clean
cd conn/jdbc_type2 && $(ANT) clean && $(MAKE) clean
cd rest && $(MAKE) clean
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/T4Messages.properties
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/T4Messages.properties b/core/conn/jdbcT4/src/main/java/T4Messages.properties
new file mode 100644
index 0000000..24d6fb1
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/T4Messages.properties
@@ -0,0 +1,686 @@
+# @@@ START COPYRIGHT @@@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# @@@ END COPYRIGHT @@@
+##############################################################
+
+#
+# Messages for T2 Driver
+#
+
+unsupported_feature_msg=Unsupported feature - {0}
+unsupported_feature_sqlstate=HYC00
+unsupported_feature_sqlcode=29001
+
+invalid_connection_msg=Connection does not exist
+invalid_connection_sqlstate=08003
+invalid_connection_sqlcode=29002
+
+invalid_statement_msg=Statement does not exist
+invalid_statement_sqlstate=HY000
+invalid_statement_sqlcode=29003
+
+invalid_transaction_isolation_msg=Invalid transaction isolation value
+invalid_transaction_isolation_sqlstate=HY024
+invalid_transaction_isolation_sqlcode=29004
+
+invalid_resultset_type_msg=Invalid ResultSet Type
+invalid_resultset_type_sqlstate=HY024
+invalid_resultset_type_sqlcode=29005
+
+invalid_resultset_concurrency_msg=Invalid Result Set Concurrency
+invalid_resultset_concurrency_sqlstate=HY000
+invalid_resultset_concurrency_sqlcode=29006
+
+invalid_desc_index_msg=Invalid descriptor index
+invalid_desc_index_sqlstate=07009
+invalid_desc_index_sqlcode=29007
+
+invalid_cursor_state_msg=Invalid cursor State
+invalid_cursor_state_sqlstate=24000
+invalid_cursor_state_sqlcode=29008
+
+invalid_cursor_position_msg=Invalid cursor position
+invalid_cursor_position_sqlstate=HY109
+invalid_cursor_position_sqlcode=29009
+
+invalid_column_name_msg=Invalid column name
+invalid_column_name_sqlstate=07009
+invalid_column_name_sqlcode=29010
+
+invalid_column_index_msg=Invalid column index or descriptor index
+invalid_column_index_sqlstate=07009
+invalid_column_index_sqlcode=29011
+
+restricted_data_type_msg=Restricted data type attribute violation
+restricted_data_type_sqlstate=07006
+restricted_data_type_sqlcode=29012
+
+invalid_fetch_size_msg=Fetch size is less than 0
+invalid_fetch_size_sqlstate=HY024
+invalid_fetch_size_sqlcode=29013
+
+fetch_output_inconsistent_msg=General Error - Programming error in next()
+fetch_output_inconsistent_sqlstate=HY000
+fetch_output_inconsistent_sqlcode=29014
+
+invalid_fetch_direction_msg=Invalid fetch direction
+invalid_fetch_direction_sqlstate=HY024
+invalid_fetch_direction_sqlcode=29015
+
+reverse_fetch_not_supported_msg=ResultSet.FETCH_REVERSE not supported
+reverse_fetch_not_supported_sqlstate=HYC00
+reverse_fetch_not_supported_sqlcode=29016
+
+datatype_not_supported_msg=SQL Data type not supported
+datatype_not_supported_sqlstate=HY004
+datatype_not_supported_sqlcode=29017
+
+invalid_cast_specification_msg=Invalid character value in cast specification
+invalid_cast_specification_sqlstate=22018
+invalid_cast_specification_sqlcode=29018
+
+parameter_not_set_msg=Parameter {0, number, integer} for {1, number, integer} set of parameters is not set
+parameter_not_set_sqlstate=07002
+parameter_not_set_sqlcode=29019
+
+invalid_parameter_index_msg=Invalid Parameter Index
+invalid_parameter_index_sqlstate=07009
+invalid_parameter_index_sqlcode=29020
+
+object_type_not_supported_msg=Object Type Not Supported
+object_type_not_supported_sqlstate=HY004
+object_type_not_supported_sqlcode=29021
+
+function_sequence_error_msg=Function Sequence Error
+function_sequence_error_sqlstate=HY010
+function_sequence_error_sqlcode=29022
+
+commit_not_allowed_msg=Commit not allowed in Transaction Aware driver
+commit_not_allowd_sqlstate=HY000
+commit_not_allowd_sqlcode=29023
+
+rollback_not_allowed_msg=Rollback not allowed in Transaction Aware Driver
+rollback_not_allowed_sqlstate=HY000
+rollback_not_allowed_sqlcode=29024
+
+setautocommit_not_allowed_msg=SetAutoCommit not allowed in Transaction Aware Driver
+setautocommit_not_allowed_sqlstate=HY000
+setautocommit_not_allowed_sqlcode=29025
+
+invalid_commit_mode_msg=Transaction can't be committed or rolled back when AutoCommit mode is on
+invalid_commit_mode_sqlstate=HY000
+invalid_commit_mode_sqlcode=29026
+
+autocommit_txn_in_progress_msg=SetAutoCommit not possible, since a transaction is active
+autocommit_txn_in_progress_sqlstate=HY011
+autocommit_txn_in_progress_sqlcode=29027
+
+read_only_connect_msg=Connection is set to read only
+read_only_connect_sqlstate=HY000
+read_only_connect_sqlcode=29028
+
+txn_isolation_txn_in_progress_msg=SetTransactionIsolation not possible, since a transaction is active
+txn_isolation_txn_in_progress_sqlstate=HY011
+txn_isolation_txn_in_progress_sqlcode=29029
+
+forward_only_cursor_msg=Result Set type is TYPE_FORWARD_ONLY
+forward_only_cursor_sqlstate=HY109
+forward_only_cursor_sqlcode=29029
+
+read_only_concur_msg=Result Set Concurrecy is CONCUR_READ_ONLY
+read_only_concur_sqlstate=HY109
+read_only_concur_sqlcode=29030
+
+select_in_batch_not_supported_msg=SELECT sql statements in batch is illgeal
+select_in_batch_not_supported_sqlstate=HY000
+select_in_batch_not_supported_sqlcode=29031
+
+row_modified_msg=The row is modified since it is last read
+row_modified_sqlstate=23000
+row_modified_sqlcode=29032
+
+primary_key_not_updateable_msg=The primary key column value can't be updated
+primary_key_not_updateable_sqlstate=23000
+primary_key_not_updateable_sqlcode=29033
+
+deprecated_method_msg=The method {0} is deprecated
+deprecated_method_sqlstate=HY000
+deprecated_method_sqlcode=29034
+
+io_exception_msg=IO Exception occurred {0}
+io_exception_sqlstate=HY000
+io_exception_sqlcode=29035
+
+unsupported_encoding_msg=Unsupported encoding {0}
+unsupported_encoding_sqlstate=HY000
+unsupported_encoding_sqlcode=29036
+
+forward_only_cursor_msg=The Result Set Type is TYPE_FORWARD_ONLY
+forward_only_cursor_sqlstate=HY106
+forward_only_cursor_sqlcode=29037
+
+invalid_row_number_msg=The row number is not valid
+invalid_row_number_sqlstate=HY107
+invalid_row_number_sqlcode=29038
+
+read_only_concur_msg=The concurrency mode of the result set is CONCUR_READ_ONLY
+read_only_concur_sqlstate=HY092
+read_only_concur_sqlcode=29039
+
+invalid_operation_msg=Operation invalid, since the current row is insert row
+invalid_operation_sqlstate=HY000
+invalid_operation_sqlcode=29040
+
+no_primary_key_msg=Operation not allowed since there is no primary key for the table
+no_primary_key_sqlstate=HY000
+no_primary_key_sqlcode=29041
+
+invalid_fetchSize_value_msg=Fetch size value is not valid
+invalid_fetchSize_value_sqlstate=HY000
+invalid_fetchSize_value_sqlcode=29042
+
+invalid_maxRows_value_msg=Max rows value is not valid
+invalid_maxRows_value_sqlstate=HY000
+invalid_maxRows_value_sqlcode=29043
+
+invalid_queryTimeout_value_msg=Query timeout value is not valid
+invalid_queryTimeout_value_sqlstate=HY000
+invalid_queryTimeout_value_sqlcode=29044
+
+data_truncation_msg=Fractional truncation
+data_truncation_sqlstate=01S07
+data_truncation_sqlcode=29045
+
+numeric_out_of_range_msg=Numeric value out of range
+numeric_out_of_range_sqlstate=22003
+numeric_out_of_range_sqlcode=29046
+
+batch_command_failed_msg=Batch Update Failed, See next exception for details
+batch_command_failed_sqlstate=HY000
+batch_command_failed_sqlcode=29047
+
+invalid_use_of_null_msg=Invalid use of null
+invalid_use_of_null_sqlstate=HY009
+invalid_use_of_null_sqlcode=29048
+
+invalid_transaction_state_msg=Invalid transaction state
+invalid_transaction_state_sqlstate=25000
+invalid_transaction_state_sqlcode=29049
+
+invalid_row_msg=Row value out of range
+invalid_row_sqlstate=HY107
+invalid_row_sqlcode=29050
+
+scrollResultSetChanged_msg=Result Set Type changed to TYPE_SCROLL_INSENSITIVE
+scrollResultSetChanged_sqlstate=01S02
+scrollResultSetChanged_sqlcode=29051
+
+invalid_holdability_state_msg=Invalid cursor holdability
+invalid_holdability_state_sqlstate=25000
+invalid_holdability_state_sqlcode=29052
+
+select_invalid_msg=Select SQL statement is invalid in executeUpdate() method
+select_invalid_sqlstate=HY000
+select_invalid_sqlcode=29053
+
+non_select_invalid_msg=Non-Select SQL statement is invalid in executeQuery() method
+non_select_invalid_sqlstate=HY000
+non_select_invalid_sqlcode=29054
+
+connection_in_use_msg=Connection is in use
+connection_in_use_sqlstate=HY000
+connection_in_use_sqlcode=29055
+
+stmt_closed_msg=Statement is already closed
+stmt_closed_sqlstate=HY000
+stmt_closed_sqlcode=29056
+
+auto_generated_keys_not_supported_msg=Auto generated keys not supported
+auto_generated_keys_not_supported_sqlstate=HY000
+auto_generated_keys_not_supported_sqlcode=29057
+
+null_pooled_connection_msg=Connection is not associated with a PooledConnection object
+null_pooled_connection_sqlstate=HY000
+null_pooled_connection_sqlcode=29058
+
+#
+# New messages for T4 driver
+#
+
+internal_error_msg=An internal error occurred
+internal_error_sqlstate=HY000
+internal_error_sqlcode=29100
+
+contact_hp_error_msg=Contact your service provider
+contact_hp_error_sqlstate=HY000
+contact_hp_error_sqlcode=29101
+
+address_parsing_error_msg=Error while parsing address {0}
+address_parsing_error_sqlstate=HY000
+address_parsing_error_sqlcode=29102
+
+address_null_error_msg=Address is null
+address_null_error_sqlstate=HY000
+address_null_error_sqlcode=29103
+
+odbc_server_suffix_error_msg=Expected suffix: {0}
+odbc_server_suffix_error_sqlstate=HY000
+odbc_server_suffix_error_sqlcode=29104
+
+unknown_prefix_error_msg=Unknown prefix for address
+unknown_prefix_error_sqlstate=HY000
+unknown_prefix_error_sqlcode=29105
+
+jdbc_address_error_msg=Expected address format: jdbc:subprotocol:subname
+jdbc_address_error_sqlstate=HY000
+jdbc_address_error_sqlcode=29106
+
+min_address_length_error_msg=Address is not long enough to be a valid address
+min_address_length_error_sqlstate=HY000
+min_address_length_error_sqlcode=29107
+
+address_format_1_error_msg=Expecting \\<machine name>.<process name>/<port number>
+address_format_1_error_sqlstate=HY000
+address_format_1_error_sqlcode=29108
+
+address_format_2_error_msg=//<{IP Address|Machine Name}[:port]>/<database name>
+address_format_2_error_sqlstate=HY000
+address_format_2_error_sqlcode=29109
+
+missing ip_or_name_error_msg=Address is missing an IP address or machine name
+missing ip_or_name_error_sqlstate=HY000
+missing ip_or_name_error_sqlcode=29110
+
+address_lookup_error_msg=Unable to evaluate address {0} Cause: {1}
+address_lookup_error_sqlstate=HY000
+address_lookup_error_sqlcode=29111
+
+address_missing_close_bracket_msg=Missing ']'
+address_missing_close_bracket_sqlstate=HY000
+address_missing_close_bracket_sqlcode=29112
+
+socket_open_error_msg=error while opening socket. Cause: {0}
+socket_open_error_sqlstate=HY000
+socket_open_error_sqlcode=29113
+
+socket_write_error_msg=error while writing to socket
+socket_write_error_sqlstate=HY000
+socket_write_error_sqlcode=29114
+
+socket_read_error_msg=error while reading from socket. Cause: {0}
+socket_read_error_sqlstate=HY000
+socket_read_error_sqlcode=29115
+
+socket_is_closed_error_msg=Socket is closed
+socket_is_closed_error_sqlstate=HY000
+socket_is_closed_error_sqlcode=29116
+
+session_close_error_msg=Error while closing session. Cause: {0}
+session_close_error_sqlstate=HY000
+session_close_error_sqlcode=29117
+
+bad_map_ptr=A write to a bad map pointer occurred
+bad_map_ptr_sqlstate=HY000
+bad_map_ptr_sqlcode=29118
+
+bad_par_ptr=A write to a bad par pointer occurred
+bad_par_ptr_sqlstate=HY000
+bad_par_ptr_sqlcode=29119
+
+dcs_connect_message_error_msg=An dcs server connect message error occurred. Cause: {0}
+dcs_connect_message_error_sqlstate=HY000
+dcs_connect_message_error_sqlcode=29120
+
+close_message_error_msg=A close message error occurred. Cause: {0}
+close_message_error_sqlstate=HY000
+close_message_error_sqlcode=29121
+
+end_transaction_message_error_msg=An end transaction message error occurred. Cause: {0}
+end_transaction_message_error_sqlstate=HY000
+end_transaction_message_error_sqlcode=29122
+
+execute_call_message_error_msg=An execute call message error occurred. Cause: {0}
+execute_call_message_error_sqlstate=HY000
+execute_call_message_error_sqlcode=29123
+
+execute_direct_message_error_msg=An execute direct message error occurred. Cause: {0}
+execute_direct_message_error_sqlstate=HY000
+execute_direct_message_error_sqlcode=29124
+
+execute_direct_rowset_message_error_msg=An execute direct rowset message error occurred. Cause: {0}
+execute_direct_rowset_message_error_sqlstate=HY000
+execute_direct_rowset_message_error_sqlcode=29125
+
+execute_n_message_error_msg =An execute N message error occurred. Cause: {0}
+execute_n_message_error_sqlstate=HY000
+execute_n_message_error_sqlcode=29126
+
+execute_rowset_message_error_msg=An execute rowset message error occurred. Cause: {0}
+execute_rowset_message_error_sqlstate=HY000
+execute_rowset_message_error_sqlcode=29127
+
+fetch_perf_message_error_msg=A fetch perf message error occurred. Cause: {0}
+fetch_perf_message_error_sqlstate=HY000
+fetch_perf_message_error_sqlcode=29128
+
+fetch_rowset_message_error_msg=A fetch rowset message error occurred. Cause: {0}
+fetch_rowset_message_error_sqlstate=HY000
+fetch_rowset_message_error_sqlcode=29129
+
+get_sql_catalogs_message_error_msg=A get sql catalogs message error occurred. Cause: {0}
+get_sql_catalogs_message_error_sqlstate=HY000
+get_sql_catalogs_message_error_sqlcode=29130
+
+initialize_dialogue_message_error=An initialize dialogue message error occurred. Cause: {0}
+initialize_dialogue_message_error_sqlstate=HY000
+initialize_dialogue_message_error_sqlcode=29131
+
+prepare_message_error_msg=A prepare message error occurred. Cause: {0}
+prepare_message_error_sqlstate=HY000
+prepare_message_error_sqlcode=29132
+
+prepare_rowset_message_error_msg=A prepare rowset message error occurred. Cause: {0}
+prepare_rowset_message_error_sqlstate=HY000
+prepare_rowset_message_error_sqlcode=29133
+
+set_connection_option_message_error_msg=A set connection option message error occurred. Cause: {0}
+set_connection_option_message_error_sqlstate=HY000
+set_connection_option_message_error_sqlcode=29134
+
+terminate_dialogue_message_error_msg=A terminate dialogue message error occurred: Cause {0}
+terminate_dialogue_message_error_sqlstate=HY000
+terminate_dialogue_message_error_sqlcode=29135
+
+dcs_connect_reply_error_msg=An dcs server connect reply error occurred. Exception: {0} Exception detail: {1} Error text/code: {2}
+dcs_connect_reply_error_sqlstate=HY000
+dcs_connect_reply_error_sqlcode=29136
+
+close_reply_error_msg=A close reply error occurred
+close_reply_error_sqlstate=HY000
+close_reply_error_sqlcode=29137
+
+end_transaction_reply_error_msg=An end transaction reply error occurred
+end_transaction_reply_error_sqlstate=HY000
+end_transaction_reply_error_sqlcode=29138
+
+execute_call_reply_error_msg=An execute call reply error occurred
+execute_call_reply_error_sqlstate=HY000
+execute_call_reply_error_sqlcode=29139
+
+execute_direct_reply_error_msg=An execute direct reply error occurred
+execute_direct_reply_error_sqlstate=HY000
+execute_direct_reply_error_sqlcode=29140
+
+execute_direct_rowset_reply_error_msg=An execute direct rowset reply error occurred
+execute_direct_rowset_reply_error_sqlstate=HY000
+execute_direct_rowset_reply_error_sqlcode=29141
+
+execute_n_reply_error_msg=An execute N reply error occurred
+execute_n_reply_error_sqlstate=HY000
+execute_n_reply_error_sqlcode=29142
+
+execute_rowset_reply_error_msg=An execute rowset reply error occurred
+execute_rowset_reply_error_sqlstate=HY000
+execute_rowset_reply_error_sqlcode=29143
+
+fetch_perf_reply_error_msg=A fetch perf reply error occurred
+fetch_perf_reply_error_sqlstate=HY000
+fetch_perf_reply_error_sqlcode=29144
+
+fetch_rowset_reply_error_msg=A fetch rowset reply error occurred
+fetch_rowset_reply_error_sqlstate=HY000
+fetch_rowset_reply_error_sqlcode=29145
+
+get_sql_catalogs_reply_error_msg=A get sql catalogs reply error occurred
+get_sql_catalogs_reply_error_sqlstate=HY000
+get_sql_catalogs_reply_error_sqlcode=29146
+
+initialize_dialogue_reply_error_msg=An initialize dialogue reply error occurred
+initialize_dialogue_reply_error_sqlstate=HY000
+initialize_dialogue_reply_error_sqlcode=29147
+
+prepare_reply_error_msg=A prepare reply error occurred
+prepare_reply_error_sqlstate=HY000
+prepare_reply_error_sqlcode=29148
+
+prepare_rowset_reply_error_msg=A prepare rowset reply error occurred
+prepare_rowset_reply_error_sqlstate=HY000
+prepare_rowset_reply_error_sqlcode=29149
+
+set_connection_option_reply_error_msg=A set connection option reply error occurred
+set_connection_option_reply_error_sqlstate=HY000
+set_connection_option_reply_error_sqlcode=29150
+
+terminate_dialogue_reply_error_msg=A terminate dialogue reply error occurred
+terminate_dialogue_reply_error_sqlstate=HY000
+terminate_dialogue_reply_error_sqlcode=29151
+
+ids_port_not_available_msg=No more ports available to start NDCS servers
+ids_port_not_available_sqlstate=HY000
+ids_port_not_available_sqlcode=29152
+
+ids_28_000_msg=Invalid authorization specification
+ids_28_000_sqlstate=HY000
+ids_28_000_sqlcode=29153
+
+ids_s1_t00_msg=Timeout expired
+ids_s1_t00_sqlstate=HY000
+ids_s1_t00_sqlcode=29154
+
+unknown_message_type_error_msg=Unknown message type
+unknown_message_type_error_sqlstate=HY000
+unknown_message_type_error_sqlcode=29155
+
+driver_err_error_from_server_msg=An error was returned from the server. Error: {0} Error detail: {1}
+driver_err_error_from_server_sqlstate=HY000
+driver_err_error_from_server_sqlcode=29156
+
+problem_with_server_read_msg=There was a problem reading from the server
+problem_with_server_read_sqlstate=HY000
+problem_with_server_read_sqlcode=29157
+
+wrong_header_version_msg=The message header contained the wrong version: {0}
+wrong_header_version_sqlstate=HY000
+wrong_header_version_sqlcode=29158
+
+wrong_header_signature_msg=The message header contained the wrong signature. Expected: {0} Actual: {1}
+wrong_header_signature_sqlstate=HY000
+wrong_header_signature_sqlcode=29159
+
+header_not_long_enough_msg=The message header was not long enough
+header_not_long_enough_sqlstate=HY000
+header_not_long_enough_sqlcode=29160
+
+ids_unable_to_logon_msg=Unable to authenticate the user because of an NT error: {0}
+ids_unable_to_logon_sqlstate=S1000
+ids_unable_to_logon_sqlcode=29161
+
+ids_program_error_msg=Unexpected programming exception has been found: {0}. Check the server event log on node {1} for details.
+ids_program_error_sqlstate=S1000
+ids_program_error_sqlcode=29162
+
+ids_dcs_srvr_not_available_msg=DCS Services not yet available: {0}
+ids_dcs_srvr_not_available_sqlstate=08001
+ids_dcs_srvr_not_available_sqlcode=29163
+
+ids_ds_not_available_msg=DataSource not yet available or not found: {0}
+ids_ds_not_available_sqlstate=08001
+ids_ds_not_available_sqlcode=29164
+
+unknown_connect_error_msg=Unknown connect reply error: {0}
+unknown_connect_error_sqlstate=HY000
+unknown_connect_error_sqlcode= 29165
+
+ids_08_004_01_msg=Data source rejected establishment of connection since the NDCS Server is connected to a different client now
+ids_08_004_01_sqlstate=08004
+ids_08_004_01_sqlcode=HY000
+
+ids_transaction_error_msg=A TIP transaction error {0} has been detected. Check the server event log on Node {1} for Transaction Error details.
+ids_transaction_error_sqlstate=S1000
+ids_transaction_error_sqlcode=HY000
+
+ids_08_s01_msg=Communication link failure. The server timed out or disappeared.
+ids_08_s01_sqlstate=08S01
+ids_08_s01_sqlcode=01032
+
+ids_s1_008_msg=Operation cancelled.
+ids_s1_008_sqlstate=S1008
+ids_s1_008_sqlcode=01118
+
+ids_25_000_msg=Invalid transaction state.
+ids_25_000_sqlstate=25000
+ids_25_000_sqlcode=01056
+
+internal_error_method_not_implemented_msg=Internal error. This method is not implemented.
+internal_error_method_not_implemented_sqlstate=HY000
+internal_error_method_not_implemented_sqlcode=29166
+
+internal_error_inconsistency_check_msg=Internal error. An internal index failed consistency check.
+internal_error_inconsistency_check_sqlstate=HY000
+internal_error_inconsistency_check_sqlcode=29167
+
+ids_unknown_reply_error_msg=Unknown reply message error: {0} error detail: {1}
+ids_unknown_reply_error_sqlstate=HY000
+ids_unknown_reply_error_sqlcode=29168
+
+ids_retry_attempt_exceeded_msg=Retry attempts to connect to the datasource failed. Maybe NDCS server is not available.
+ids_retry_attempt_exceeded_sqlstate=08001
+ids_retry_attempt_exceeded_sqlcode=HY000
+
+invalid_property_msg=Invalid connection property setting: {0}
+invalid_property_sqlstate=HY000
+invalid_property_sqlcode=29169
+
+invalid_parameter_value_msg=Invalid Parameter Value: {0}
+invalid_parameter_value_sqlstate=HY000
+invalid_parameter_value_sqlcode=29170
+
+resource_governing_msg=Failed since resource governing policy is hit
+resource_governing_sqlstate=S1000
+resource_governing_sqlcode=29171
+
+translation_of_parameter_failed_msg=Translation of parameter to {0} failed. Cause: {1}
+translation_of_parameter_failed_sqlstate=HY000
+translation_of_parameter_failed_sqlcode=29172
+
+#
+# New Messages for LOB Support From Type 2
+#
+
+no_blobTableName_msg='blobTableName' property is not set or set to null value or set to invalid value
+no_blobTableName_sqlstate=HY000
+no_blobTableName_sqlcode=29059
+
+no_clobTableName_msg='clobTableName' property is not set or set to null value or set to invalid value
+no_clobTableName_sqlstate=HY000
+no_clobTableName_sqlcode=29060
+
+invalid_lob_commit_state_msg=Autocommit is on and LOB objects are involved
+invalid_lob_commit_state_sqlstate=HY000
+invalid_lob_commit_state_sqlcode=29069
+
+lob_not_current_msg=Lob object {0} is not current
+lob_not_current_sqlstate=HY000
+lob_not_current_sqlcode=29061
+
+invalid_input_value_msg=Invalid input value in the method {0}
+invalid_input_value_sqlstate=07009
+invalid_input_value_sqlcode=29067
+
+invalid_position_value_msg=The value for position can be any value between 1 and one more than the length of the lob data
+invalid_position_value_sqlstate=07009
+invalid_position_value_sqlcode=29068
+
+problem_with_logging_msg=There was a problem while logging: {0}
+problem_with_logging_sqlstate=HY000
+problem_with_logging_sqlcode=29070
+
+initial_pool_creation_error_msg=Error occurred while creating the initial pool of {0} connection(s)
+initial_pool_creation_error_sqlstate=HY000
+initial_pool_creation_error_sqlcode=29173
+
+resultSet_updateRow_with_autocommit_msg=Autocommit is on and updateRow was called on the ResultSet object
+resultSet_updateRow_with_autocommit_sqlstate=HY000
+resultSet_updateRow_with_autocommit_sqlcode=29174
+
+unknown_error_msg=Unknown Error {0}
+unknown_error_sqlstate=HY000
+unknown_error_sqlcode=29175
+
+fill_in_SQL_Values_msg=Failed while converting objects to SQL values.
+fill_in_SQL_Values_sqlstate=HY000
+fill_in_SQL_Values_sqlcode=29176
+
+null_data_msg=Data cannot be null.
+null_data_sqlstate=HY000
+null_data_sqlcode=29177
+
+no_column_value_specified_msg=No column value has been inserted
+no_column_value_specified_sqlstate=HY000
+no_column_value_specified_sqlcode=29178
+
+
+execute_2_message_error_msg =An Execute2 message error occurred. Cause: {0}
+execute_2_message_error_sqlstate=HY000
+execute_2_message_error_sqlcode=29179
+
+infostats_invalid_error_msg=INFOSTATS command is supported only via the Statement.execute(String sql) method.
+infostats_invalid_error_sqlstate=HY000
+infostats_invalid_error_sqlcode=29180
+
+dcs_cancel_message_error_msg=A dcs server cancel message error occurred. Cause: {0}
+dcs_cancel_message_error_sqlstate=HY000
+dcs_cancel_message_error_sqlcode=29181
+
+connected_to_Default_DS_msg= General warning. Connected to the default data source: {0}
+connected_to_Default_DS_sqlstate=HY000
+connected_to_Default_DS_sqlcode=29182
+
+invalid_string_parameter_msg=Invalid Parameter Value: {0}
+invalid_string_parameter_sqlstate=22001
+invalid_string_parameter_sqlcode=29183
+
+null_parameter_for_not_null_column_msg=NULL cannot be assigned to a NOT NULL column, parameter {0}.
+null_parameter_for_not_null_column_sqlstate=23000
+null_parameter_for_not_null_column_sqlcode=29184
+
+security_error_msg=A Security Exception Occurred: {0}
+security_error_sqlstate=HY000
+security_error_sqlcode=29185
+
+certificate_download_error_msg=An error occurred while downloading the certificate: {0}
+certificate_download_error_sqlstate=HY000
+certificate_download_error_sqlcode=29186
+
+data_truncation_exceed_msg=The data length {0} exceeds the max length {1}
+data_truncation_exceed_sqlstate=HY000
+data_truncation_exceed_sqlcode=29187
+
+numeric_out_of_range_d_msg=Numeric value {0} is out of range [{1}, {2}]
+numeric_out_of_range_d_sqlstate=22003
+numeric_out_of_range_d_sqlcode=29188
+
+cursor_is_before_first_row_msg=The cursor is before the first row, therefore no data can be retrieved
+cursor_is_before_first_row_sqlstate=HY109
+cursor_is_before_first_row_sqlcode=29189
+
+cursor_after_last_row_msg=The cursor is after last row, which could be due to the result set containing no rows, or all rows have been retrieved.
+cursor_after_last_row_sqlstate=HY109
+cursor_after_last_row_sqlcode=29190
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Address.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Address.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Address.java
new file mode 100644
index 0000000..d486f57
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Address.java
@@ -0,0 +1,117 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+/**********************************************************
+ * This class represents an address reference.
+ *
+ *
+ **********************************************************/
+
+import java.net.InetAddress;
+import java.sql.SQLException;
+import java.util.Locale;
+import java.util.Properties;
+
+abstract class Address {
+ protected Locale m_locale;
+ protected T4Properties m_t4props;
+ protected String m_ipAddress;
+ protected String m_machineName;
+ protected String m_processName;
+ protected Integer m_portNumber;
+ protected Properties m_properties;
+ InetAddress[] m_inetAddrs;
+ protected int m_type;
+ protected String m_url;
+ protected InputOutput m_io;
+
+ /**
+ * The constructor.
+ *
+ * @param addr
+ * The addr has two forms:
+ *
+ * DriverManager getConnection addr parameter format for connecting via the
+ * Fast JDBC Type 3 driver.
+ *
+ * jdbc:subprotocol:subname
+ *
+ * Where:
+ *
+ * subprotocol = t4jdbc
+ *
+ * subname = //<{IP Address|Machine Name}[:port]>/<database name>
+ *
+ * Example: jdbc:t4jdbc://130.168.200.30:1433/database1
+ *
+ *
+ * ODBC server connect format returned by the ODBC Association Server.
+ *
+ * TCP:\<{IP Address|Machine Name}>.<Process Name>/<port>:ODBC
+ *
+ */
+
+ // ----------------------------------------------------------
+ Address(T4Properties t4props, Locale locale, String addr) throws SQLException {
+ m_t4props = t4props;
+ m_locale = locale;
+ m_url = addr;
+ }
+
+ abstract String recreateAddress();
+
+ // ----------------------------------------------------------
+ String getIPorName() {
+ if (m_machineName != null) {
+ return m_machineName;
+ } else {
+ return m_ipAddress;
+ }
+ } // end getIPorName
+
+ protected boolean validateAddress() throws SQLException {
+ String IPorName = getIPorName();
+ try {
+ m_inetAddrs = InetAddress.getAllByName(IPorName);
+ } catch (Exception e) {
+ SQLException se = HPT4Messages.createSQLException(m_t4props, m_locale, "address_lookup_error", m_url, e
+ .getMessage());
+ se.initCause(e);
+ throw se;
+ }
+ return true;
+ }
+
+ // ----------------------------------------------------------
+ Integer getPort() {
+ return m_portNumber;
+ } // end getIPorName
+
+ void setInputOutput() {
+ m_io = new InputOutput(m_locale, this);
+ }
+
+ InputOutput getInputOutput() {
+ return m_io;
+ }
+} // end class Address
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/BaseRow.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/BaseRow.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/BaseRow.java
new file mode 100644
index 0000000..3d28248
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/BaseRow.java
@@ -0,0 +1,65 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+/*
+ * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation. Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package org.trafodion.jdbc.t4;
+
+import java.io.Serializable;
+import java.sql.SQLException;
+
+abstract class BaseRow implements Serializable, Cloneable {
+
+ protected Object origVals[];
+
+ BaseRow() {
+ }
+
+ protected abstract Object getColumnObject(int i) throws SQLException;
+
+ protected Object[] getOrigRow() {
+ return origVals;
+ }
+
+ protected abstract void setColumnObject(int i, Object obj) throws SQLException;
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Bytes.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Bytes.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Bytes.java
new file mode 100644
index 0000000..78803c3
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Bytes.java
@@ -0,0 +1,269 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+/**
+ * <code>Bytes</code> contains a set of static methods used for byte
+ * manipulation. There are three basic types of methods:
+ * <ul>
+ * <li>extract</li>
+ * <li>insert</li>
+ * <li>create</li>
+ * </ul>
+ * <p>
+ * Extract methods will copy from a raw byte array into a basic Java type.
+ * Insert methods will copy from a basic Java type into a raw byte array. Create
+ * methods will copy from a basic Java type into a new raw byte array which is
+ * returned to the user.
+ *
+ * As Java is always BigEndian, set the swap parameter to <code>true</code> to
+ * convert to and from LittleEndian.
+ *
+ * There is no error checking in order to improve performance. Length checking
+ * should be done before calling these methods or the resulting exceptions
+ * should be handled by the user.
+ *
+ */
+class Bytes {
+
+ static short extractShort(byte[] array, int offset, boolean swap) {
+ short value;
+
+ if (swap) {
+ value = (short) (((array[offset]) & 0x00ff) | ((array[offset + 1] << 8) & 0xff00));
+ } else {
+ value = (short) (((array[offset + 1]) & 0x00ff) | ((array[offset] << 8) & 0xff00));
+ }
+
+ return value;
+ }
+
+ static int extractUShort(byte[] array, int offset, boolean swap) {
+ int value;
+
+ if (swap) {
+ value = ((array[offset]) & 0x00ff) | ((array[offset + 1] << 8) & 0xff00);
+ } else {
+ value = ((array[offset + 1]) & 0x00ff) | ((array[offset] << 8) & 0xff00);
+ }
+
+ return value & 0xffff;
+ }
+
+ static int extractInt(byte[] array, int offset, boolean swap) {
+ int value;
+
+ if (swap) {
+ value = ((array[offset]) & 0x000000ff) | ((array[offset + 1] << 8) & 0x0000ff00)
+ | ((array[offset + 2] << 16) & 0x00ff0000) | ((array[offset + 3] << 24) & 0xff000000);
+ } else {
+ value = ((array[offset + 3]) & 0x000000ff) | ((array[offset + 2] << 8) & 0x0000ff00)
+ | ((array[offset + 1] << 16) & 0x00ff0000) | ((array[offset] << 24) & 0xff000000);
+ }
+
+ return value;
+ }
+
+ static long extractUInt(byte[] array, int offset, boolean swap) {
+ long value;
+
+ if (swap) {
+ value = ((array[offset]) & 0x000000ff) | ((array[offset + 1] << 8) & 0x0000ff00)
+ | ((array[offset + 2] << 16) & 0x00ff0000) | ((array[offset + 3] << 24) & 0xff000000);
+ } else {
+ value = ((array[offset + 3]) & 0x000000ff) | ((array[offset + 2] << 8) & 0x0000ff00)
+ | ((array[offset + 1] << 16) & 0x00ff0000) | ((array[offset] << 24) & 0xff000000);
+ }
+
+ return value & 0xffffffffL;
+ }
+
+ static long extractLong(byte[] array, int offset, boolean swap) {
+ long value = 0;
+ int i=offset;
+
+ if(swap) {
+ for (int shift = 0; shift < 64; shift += 8) {
+ value |= ( (long)( array[i] & 0xff ) ) << shift;
+ i++;
+ }
+
+ }else {
+ for (int shift = 56; shift >= 0; shift -= 8) {
+ value |= ( (long)( array[i] & 0xff ) ) << shift;
+ i++;
+ }
+ }
+
+ return value;
+ }
+
+ static int insertShort(byte[] array, int offset, short value, boolean swap) {
+ if (swap) {
+ array[offset + 1] = (byte) ((value >>> 8) & 0xff);
+ array[offset] = (byte) ((value) & 0xff);
+ } else {
+ array[offset] = (byte) ((value >>> 8) & 0xff);
+ array[offset + 1] = (byte) ((value) & 0xff);
+ }
+
+ return offset + 2;
+ }
+
+ /*
+ * static int insertUShort(byte[] array, int offset, int value, boolean
+ * swap) {
+ *
+ * return offset + 2; }
+ */
+
+ static int insertInt(byte[] array, int offset, int value, boolean swap) {
+ if (swap) {
+ array[offset + 3] = (byte) ((value >>> 24) & 0xff);
+ array[offset + 2] = (byte) ((value >>> 16) & 0xff);
+ array[offset + 1] = (byte) ((value >>> 8) & 0xff);
+ array[offset] = (byte) ((value) & 0xff);
+ } else {
+ array[offset] = (byte) ((value >>> 24) & 0xff);
+ array[offset + 1] = (byte) ((value >>> 16) & 0xff);
+ array[offset + 2] = (byte) ((value >>> 8) & 0xff);
+ array[offset + 3] = (byte) ((value) & 0xff);
+ }
+
+ return offset + 4;
+ }
+
+ /*
+ * static int insertUInt(byte[] array, int offset, long value, boolean swap) {
+ * return offset + 4; }
+ */
+
+ static int insertLong(byte[] array, int offset, long value, boolean swap) {
+ if (swap) {
+ array[offset + 7] = (byte) ((value >>> 56) & 0xff);
+ array[offset + 6] = (byte) ((value >>> 48) & 0xff);
+ array[offset + 5] = (byte) ((value >>> 40) & 0xff);
+ array[offset + 4] = (byte) ((value >>> 32) & 0xff);
+ array[offset + 3] = (byte) ((value >>> 24) & 0xff);
+ array[offset + 2] = (byte) ((value >>> 16) & 0xff);
+ array[offset + 1] = (byte) ((value >>> 8) & 0xff);
+ array[offset] = (byte) ((value) & 0xff);
+ } else {
+ array[offset] = (byte) ((value >>> 56) & 0xff);
+ array[offset + 1] = (byte) ((value >>> 48) & 0xff);
+ array[offset + 2] = (byte) ((value >>> 40) & 0xff);
+ array[offset + 3] = (byte) ((value >>> 32) & 0xff);
+ array[offset + 4] = (byte) ((value >>> 24) & 0xff);
+ array[offset + 5] = (byte) ((value >>> 16) & 0xff);
+ array[offset + 6] = (byte) ((value >>> 8) & 0xff);
+ array[offset + 7] = (byte) ((value) & 0xff);
+ }
+
+ return offset + 8;
+ }
+
+ static byte[] createShortBytes(short value, boolean swap) {
+ byte[] b = new byte[2];
+ Bytes.insertShort(b, 0, value, swap);
+
+ return b;
+ }
+
+ /*
+ * static byte[] createUShortBytes(int value, boolean swap) { byte[] b = new
+ * byte[2]; Bytes.insertUShort(b, 0, value, swap);
+ *
+ * return b; }
+ */
+
+ static byte[] createIntBytes(int value, boolean swap) {
+ byte[] b = new byte[4];
+ Bytes.insertInt(b, 0, value, swap);
+
+
+ return b;
+ }
+
+ /*
+ * static byte[] createUIntBytes(long value, boolean swap) { byte[] b = new
+ * byte[4]; Bytes.insertUInt(b, 0, value, swap);
+ *
+ * return b; }
+ */
+
+ static byte[] createLongBytes(long value, boolean swap) {
+ byte[] b = new byte[8];
+ Bytes.insertLong(b, 0, value, swap);
+
+ return b;
+ }
+
+ // -------------------------------------------------------------
+ // -------------------------------------------------------------
+ // ---------------TODO: get rid of these methods!---------------
+ // -------------------------------------------------------------
+ // -------------------------------------------------------------
+
+ /**
+ * @deprecated
+ */
+ static char[] read_chars(byte[] buffer, int index) {
+ int len = 0;
+
+ // find the null terminator
+ while (buffer[index + len] != 0) {
+ len = len + 1;
+ }
+
+ char[] temp1 = read_chars(buffer, index, len);
+
+ return temp1;
+ } // end read_chars
+
+ /**
+ * @deprecated
+ */
+ static char[] read_chars(byte[] buffer, int index, int tLen) {
+ char[] la_chars;
+ int len = tLen;
+
+ if (len == -1) // must find null to get length
+ {
+ int ii = index;
+ while (buffer[ii] != (byte) 0) {
+ ii = ii + 1;
+ }
+ len = ii - index;
+ }
+
+ la_chars = new char[len];
+
+ int i = 0;
+ while (i < len) {
+ la_chars[i] = (char) (buffer[index] & 0xff);
+ i = i + 1;
+ index = index + 1;
+ }
+
+ return la_chars;
+ } // end read_chars
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CONNECTION_CONTEXT_def.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CONNECTION_CONTEXT_def.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CONNECTION_CONTEXT_def.java
new file mode 100644
index 0000000..d38b178
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CONNECTION_CONTEXT_def.java
@@ -0,0 +1,149 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.UnsupportedCharsetException;
+
+class CONNECTION_CONTEXT_def {
+ String datasource = "";
+ String catalog = "";
+ String schema = "";
+ String location = "";
+ String userRole = "";
+
+ short accessMode;
+ short autoCommit;
+ short queryTimeoutSec;
+ short idleTimeoutSec;
+ short loginTimeoutSec;
+ short txnIsolationLevel;
+ short rowSetSize;
+
+ int diagnosticFlag;
+ int processId;
+
+ String computerName = "";
+ String windowText = "";
+
+ int ctxACP;
+ int ctxDataLang;
+ int ctxErrorLang;
+ short ctxCtrlInferNXHAR;
+
+ short cpuToUse = -1;
+ short cpuToUseEnd = -1; // for future use by DBTransporter
+
+ String connectOptions = "";
+
+ VERSION_LIST_def clientVersionList = new VERSION_LIST_def();
+
+ byte[] datasourceBytes;
+ byte[] catalogBytes;
+ byte[] schemaBytes;
+ byte[] locationBytes;
+ byte[] userRoleBytes;
+ byte[] computerNameBytes;
+ byte[] windowTextBytes;
+ byte[] connectOptionsBytes;
+
+ // ----------------------------------------------------------
+ int sizeOf(InterfaceConnection ic) throws CharacterCodingException, UnsupportedCharsetException {
+ int size = 0;
+
+ datasourceBytes = ic.encodeString(datasource, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+ catalogBytes = ic.encodeString(catalog, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+ schemaBytes = ic.encodeString(schema, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+ locationBytes = ic.encodeString(location, 1);
+ userRoleBytes = ic.encodeString(userRole, 1);
+ computerNameBytes = ic.encodeString(computerName, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+ windowTextBytes = ic.encodeString(windowText, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+ connectOptionsBytes = ic.encodeString(connectOptions, 1);
+
+ size = TRANSPORT.size_bytes(datasourceBytes);
+ size += TRANSPORT.size_bytes(catalogBytes);
+ size += TRANSPORT.size_bytes(schemaBytes);
+ size += TRANSPORT.size_bytes(locationBytes);
+ size += TRANSPORT.size_bytes(userRoleBytes);
+
+ size += TRANSPORT.size_short; // accessMode
+ size += TRANSPORT.size_short; // autoCommit
+ size += TRANSPORT.size_int; // queryTimeoutSec
+ size += TRANSPORT.size_int; // idleTimeoutSec
+ size += TRANSPORT.size_int; // loginTimeoutSec
+ size += TRANSPORT.size_short; // txnIsolationLevel
+ size += TRANSPORT.size_short; // rowSetSize
+
+ size += TRANSPORT.size_short; // diagnosticFlag
+ size += TRANSPORT.size_int; // processId
+
+ size += TRANSPORT.size_bytes(computerNameBytes);
+ size += TRANSPORT.size_bytes(windowTextBytes);
+
+ size += TRANSPORT.size_int; // ctxACP
+ size += TRANSPORT.size_int; // ctxDataLang
+ size += TRANSPORT.size_int; // ctxErrorLang
+ size += TRANSPORT.size_short; // ctxCtrlInferNCHAR
+
+ size += TRANSPORT.size_short; // cpuToUse
+ size += TRANSPORT.size_short; // cpuToUseEnd
+ size += TRANSPORT.size_bytes(connectOptionsBytes);
+
+ size += clientVersionList.sizeOf();
+
+ return size;
+ }
+
+ // ----------------------------------------------------------
+ void insertIntoByteArray(LogicalByteArray buf) {
+ buf.insertString(datasourceBytes);
+ buf.insertString(catalogBytes);
+ buf.insertString(schemaBytes);
+ buf.insertString(locationBytes);
+ buf.insertString(userRoleBytes);
+
+ buf.insertShort(accessMode);
+ buf.insertShort(autoCommit);
+ buf.insertInt(queryTimeoutSec);
+ buf.insertInt(idleTimeoutSec);
+ buf.insertInt(loginTimeoutSec);
+ buf.insertShort(txnIsolationLevel);
+ buf.insertShort(rowSetSize);
+
+ buf.insertInt(diagnosticFlag);
+ buf.insertInt(processId);
+
+ buf.insertString(computerNameBytes);
+ buf.insertString(windowTextBytes);
+
+ buf.insertInt(ctxACP);
+ buf.insertInt(ctxDataLang);
+ buf.insertInt(ctxErrorLang);
+ buf.insertShort(ctxCtrlInferNXHAR);
+
+ buf.insertShort(cpuToUse);
+ buf.insertShort(cpuToUseEnd);
+ buf.insertString(connectOptionsBytes);
+
+ clientVersionList.insertIntoByteArray(buf);
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CachedPreparedStatement.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CachedPreparedStatement.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CachedPreparedStatement.java
new file mode 100644
index 0000000..5866e04
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CachedPreparedStatement.java
@@ -0,0 +1,67 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+import java.sql.PreparedStatement;
+import java.sql.SQLException;
+
+public class CachedPreparedStatement {
+
+ PreparedStatement getPreparedStatement() {
+ inUse_ = true;
+ return pstmt_;
+ }
+
+ void setLastUsedInfo() {
+ lastUsedTime_ = System.currentTimeMillis();
+ noOfTimesUsed_++;
+ }
+
+ long getLastUsedTime() {
+ return lastUsedTime_;
+ }
+
+ String getLookUpKey() {
+ return key_;
+ }
+
+ void close(boolean hardClose) throws SQLException {
+ inUse_ = false;
+ pstmt_.close(hardClose);
+ }
+
+ CachedPreparedStatement(PreparedStatement pstmt, String key) {
+ pstmt_ = (TrafT4PreparedStatement) pstmt;
+ key_ = key;
+ creationTime_ = System.currentTimeMillis();
+ lastUsedTime_ = creationTime_;
+ noOfTimesUsed_ = 1;
+ inUse_ = true;
+ }
+
+ private TrafT4PreparedStatement pstmt_;
+ private String key_;
+ private long lastUsedTime_;
+ private long creationTime_;
+ private long noOfTimesUsed_;
+ boolean inUse_;
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelMessage.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelMessage.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelMessage.java
new file mode 100644
index 0000000..b8347a2
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelMessage.java
@@ -0,0 +1,49 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.UnsupportedCharsetException;
+
+class CancelMessage {
+ static LogicalByteArray marshal(int dialogueId, int srvrType, String srvrObjRef, int stopType,
+ InterfaceConnection ic) throws UnsupportedCharsetException, CharacterCodingException {
+ int wlength = Header.sizeOf();
+ LogicalByteArray buf = null;
+
+ byte[] srvrObjRefBytes = ic.encodeString(srvrObjRef, 1);
+
+ wlength += TRANSPORT.size_int; // dialogueId
+ wlength += TRANSPORT.size_int; // srvrType
+ wlength += TRANSPORT.size_bytes(srvrObjRefBytes); // srvrObjReference
+ wlength += TRANSPORT.size_int; // stopType
+
+ buf = new LogicalByteArray(wlength, Header.sizeOf(), ic.getByteSwap());
+
+ buf.insertInt(dialogueId);
+ buf.insertInt(srvrType);
+ buf.insertString(srvrObjRefBytes);
+ buf.insertInt(stopType);
+
+ return buf;
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelReply.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelReply.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelReply.java
new file mode 100644
index 0000000..b3eb6f0
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CancelReply.java
@@ -0,0 +1,38 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+package org.trafodion.jdbc.t4;
+
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.UnsupportedCharsetException;
+import java.sql.SQLException;
+
+class CancelReply {
+ odbc_Dcs_StopSrvr_exc_ m_p1_exception;
+
+ // -------------------------------------------------------------
+ CancelReply(LogicalByteArray buf, InterfaceConnection ic) throws SQLException, CharacterCodingException,
+ UnsupportedCharsetException {
+ buf.setLocation(Header.sizeOf());
+
+ m_p1_exception = new odbc_Dcs_StopSrvr_exc_();
+ m_p1_exception.extractFromByteArray(buf, ic);
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Certificate.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Certificate.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Certificate.java
new file mode 100644
index 0000000..eedc663
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Certificate.java
@@ -0,0 +1,112 @@
+/**********************************************************************
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+ //
+ **********************************************************************/
+/**
+ * Certificate.java
+ * This class get the x509 certificate from an input file and stores
+ * the certificate in the m_cert member.
+ */
+
+package org.trafodion.jdbc.t4;
+
+import java.security.cert.X509Certificate;
+import java.security.cert.CertificateFactory;
+import java.security.cert.CertificateException;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.InputStream;
+import java.io.IOException;
+import java.util.Date;
+import java.text.SimpleDateFormat;
+import java.util.TimeZone;
+
+public class Certificate
+{
+ /**
+ * Ctor - Gets certificate and the certificate's expiration
+ * date from the certificate file.
+ * @param certFile - the certificate file which stores the
+ * public key.
+ * @throws SecurityException
+ */
+ public Certificate(File certFile)
+ throws SecurityException
+ {
+ InputStream inStream = null;
+ try
+ {
+ inStream = new FileInputStream(certFile);
+ CertificateFactory cf = CertificateFactory.getInstance("X.509");
+ m_cert = (X509Certificate) cf.generateCertificate(inStream);
+ // Get certificate expiration date
+ Date expDate = m_cert.getNotAfter();
+
+ SimpleDateFormat sdf = new SimpleDateFormat("yyMMddHHmmss");
+ sdf.setTimeZone(TimeZone.getTimeZone("GMT"));
+ String fDate = sdf.format(expDate);
+ m_certExpDate = fDate.getBytes();
+ }
+ catch (CertificateException cex)
+ {
+ throw new SecurityException(SecClientMsgKeys.FILE_CORRUPTION, new Object[]{certFile.getName()} );
+ }
+ catch (Exception ex)
+ {
+ // This should never happen
+ throw new SecurityException(SecClientMsgKeys.FILE_NOTFOUND, new Object[]{certFile.getName()} );
+ }
+ finally
+ {
+ try
+ {
+ if (inStream != null) inStream.close();
+ }
+ catch (IOException io)
+ {
+ // Notmuch to do at this point
+ }
+ }
+ }
+
+ /**
+ * returns the expiration date of the certificate
+ * @return an array of byte representing the expiration
+ * date of the certificate in the String format
+ * "yyMMddHHmmss"
+ */
+ public byte[] getCertExpDate()
+ {
+ return m_certExpDate;
+ }
+
+ /**
+ * @return the X509Certificate
+ */
+ public X509Certificate getCert()
+ {
+ return m_cert;
+ }
+
+ private X509Certificate m_cert;
+ private byte[] m_certExpDate;
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Cipher.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Cipher.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Cipher.java
new file mode 100644
index 0000000..32c0ef9
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/Cipher.java
@@ -0,0 +1,201 @@
+/**********************************************************************
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+//
+**********************************************************************/
+
+/**
+ * class Cipher - Encrypts and decrypts data and password using
+ * symmetric key and key pair
+ *
+ */
+
+package org.trafodion.jdbc.t4;
+
+import javax.crypto.spec.IvParameterSpec;
+import javax.crypto.SecretKey;
+
+
+
+public class Cipher
+{
+ private static class Holder
+ {
+ private static Cipher instance = new Cipher();
+ }
+
+ /**
+ *
+ * @return Cipher
+ */
+ public static Cipher getInstance()
+ {
+ return Holder.instance;
+ }
+
+ /** Encrypts plain text and stores the
+ * cipher text in cipherText using public key for password encryption.
+ * @param plainText - plain text to be encrypted
+ * @param cipherText - encrypted plain text is returned
+ * @param key - password encryption: public key
+ * @Return the length of the cipher text or -1 in case of error
+ * @throws SecurityException
+ */
+ public int encrypt(byte[] plainText, byte[] cipherText,
+ java.security.Key key) throws SecurityException
+ {
+ int len = 0;
+
+ if (plainText == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"plainText"});
+ if (cipherText == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"cipherText"});
+ if (key == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"key"});
+
+ try {
+ // Obtain a RSA Cipher Object
+ // RSA algorithm, ECB:Electronic Codebook Mode mode,
+ // PKCS1Padding: PKCS1 padding
+ javax.crypto.Cipher cipher = javax.crypto.Cipher.
+ getInstance("RSA/ECB/PKCS1Padding");
+ byte[] tmpCipherText;
+ synchronized(cipher) {
+ cipher.init(javax.crypto.Cipher.ENCRYPT_MODE, key);
+
+ tmpCipherText = cipher.doFinal(plainText);
+ }
+
+ System.arraycopy(tmpCipherText, 0, cipherText, 0, tmpCipherText.length);
+
+ len = cipherText.length;
+ }catch (Exception ex) {
+ throw new SecurityException(SecClientMsgKeys.ENCRYPTION_FAILED, null);
+ }
+ return len;
+ }
+
+ public static javax.crypto.Cipher getEASInstance(String algorithm) throws SecurityException
+ {
+ if (algorithm == null)
+ throw new SecurityException(SecClientMsgKeys.INPUT_PARAMETER_IS_NULL, new Object[]{"algorithm"});
+ try {
+ // Obtain a AES Cipher Object
+ // AES algorithm using a cryptographic key of 128 bits
+ // to encrypt data in blocks of 128 bits,
+ // CBC cipher mode, PKCS5Padding padding
+
+ return javax.crypto.Cipher.getInstance("AES/CBC/PKCS5Padding");
+ } catch (Exception ex) {
+ throw new SecurityException(SecClientMsgKeys.ENCRYPTION_FAILED, null);
+ }
+ }
+
+ /** Encrypts the plain text data message using "EAS256/CBC/PKCS7"
+ * @param plainText - plain text to be encrypted
+ * @param key - session key is used as secret key
+ * @param iv - 16 lower bytes of the nonce is used as the initial vector.
+ * Can't use the whole 32 bytes nonce because the IV size has
+ * to be equal to the block size which is a Java requirement.
+ * @Return the cipher text in byte
+ * @throws SecurityException
+ */
+ public static byte[] encryptData(byte[] plainText, SecretKey key, byte[] iv,
+ javax.crypto.Cipher cipher)
+ throws SecurityException
+ {
+ if (plainText == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"plainText"});
+ if (key == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"key"});
+ if (iv == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"iv"});
+
+ try {
+ IvParameterSpec initialVector = new IvParameterSpec(iv);
+
+ synchronized (cipher) {
+ cipher.init(javax.crypto.Cipher.ENCRYPT_MODE, key, initialVector);
+
+ return cipher.doFinal(plainText);
+ }
+
+ }catch (Exception ex) {
+ throw new SecurityException(SecClientMsgKeys.DATA_ENCRYPTION_FAILED, null);
+ }
+ }
+
+ /** Decrypts cipherText and stores the
+ * plain text in plainText using private key for password
+ * decryption or symmetric key for data decryption
+ *
+ * @param cipherText cipher text to be decrypted
+ * @param plainText decrypted cipher text is returned
+ * @param key password decryption: private key
+ * message encryption: session key
+ * @param iv 8 sequence nonce is used as the initial vector for symmetric
+ * key encryption. Null if is private key encryption
+ * @return the length of the plain text or -1 in case of error
+ * @throws SecurityException
+ */
+ public int decrypt(byte[] cipherText, byte[] plainText,
+ java.security.Key key, byte[] iv) throws SecurityException
+ {
+ int len = 0;
+ if (iv == null) //Private key decyption
+ {
+ if (plainText == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"plainText"});
+ if (cipherText == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"cipherText"});
+ if (key == null)
+ throw new SecurityException(SecClientMsgKeys.
+ INPUT_PARAMETER_IS_NULL, new Object[]{"key"});
+ try {
+ // Obtain a RSA Cipher Object
+ // RSA algorithm, ECB:Electronic Code book Mode mode,
+ // PKCS1Padding: PKCS1 padding
+ javax.crypto.Cipher cipher = javax.crypto.Cipher.
+ getInstance("RSA/ECB/PKCS1Padding");
+ byte[] tmpPlainText ;
+ synchronized (cipher) {
+ cipher.init(javax.crypto.Cipher.DECRYPT_MODE, key);
+ tmpPlainText = cipher.doFinal(cipherText);
+ }
+ System.arraycopy(tmpPlainText, 0, plainText, 0, tmpPlainText.length);
+
+ len = plainText.length;
+ }catch (Exception ex) {
+ throw new SecurityException(SecClientMsgKeys.DECRYPTION_FAILED, null);
+ }
+ }
+
+ return len;
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseMessage.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseMessage.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseMessage.java
new file mode 100644
index 0000000..30c23fe
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseMessage.java
@@ -0,0 +1,48 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.UnsupportedCharsetException;
+
+class CloseMessage {
+ // ----------------------------------------------------------
+ static LogicalByteArray marshal(int dialogueId, String stmtLabel, short freeResourceOpt, InterfaceConnection ic)
+ throws UnsupportedCharsetException, CharacterCodingException {
+ int wlength = Header.sizeOf();
+ LogicalByteArray buf;
+
+ byte[] stmtLabelBytes = ic.encodeString(stmtLabel, InterfaceUtilities.SQLCHARSETCODE_UTF8);
+
+ wlength += TRANSPORT.size_int; // dialogueId
+ wlength += TRANSPORT.size_bytes(stmtLabelBytes);
+ wlength += TRANSPORT.size_short; // freeResourceOpt
+
+ buf = new LogicalByteArray(wlength, Header.sizeOf(), ic.getByteSwap());
+
+ buf.insertInt(dialogueId);
+ buf.insertString(stmtLabelBytes);
+ buf.insertShort(freeResourceOpt);
+
+ return buf;
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/72e17019/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseReply.java
----------------------------------------------------------------------
diff --git a/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseReply.java b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseReply.java
new file mode 100644
index 0000000..91bb2a7
--- /dev/null
+++ b/core/conn/jdbcT4/src/main/java/org/trafodion/jdbc/t4/CloseReply.java
@@ -0,0 +1,48 @@
+// @@@ START COPYRIGHT @@@
+//
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+//
+// @@@ END COPYRIGHT @@@
+
+package org.trafodion.jdbc.t4;
+
+import java.nio.charset.CharacterCodingException;
+import java.nio.charset.UnsupportedCharsetException;
+import java.sql.SQLException;
+
+class CloseReply {
+ odbc_SQLSvc_Close_exc_ m_p1;
+ int m_p2;
+ ERROR_DESC_LIST_def m_p3;
+
+ // -------------------------------------------------------------
+ CloseReply(LogicalByteArray buf, String addr, InterfaceConnection ic) throws CharacterCodingException,
+ UnsupportedCharsetException, SQLException {
+ buf.setLocation(Header.sizeOf());
+
+ m_p1 = new odbc_SQLSvc_Close_exc_();
+ m_p1.extractFromByteArray(buf, addr, ic);
+
+ if (m_p1.exception_nr != TRANSPORT.CEE_SUCCESS) {
+ m_p2 = buf.extractInt();
+
+ m_p3 = new ERROR_DESC_LIST_def();
+ m_p3.extractFromByteArray(buf, ic);
+ }
+ }
+}