You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by da...@apache.org on 2006/04/28 20:41:10 UTC

svn commit: r397980 [2/2] - in /db/derby/code/trunk/java: client/org/apache/derby/client/ client/org/apache/derby/client/am/ client/org/apache/derby/client/net/ client/org/apache/derby/jdbc/ engine/org/apache/derby/iapi/reference/ shared/org/apache/der...

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/ParameterMetaData40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/ParameterMetaData40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/ParameterMetaData40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/ParameterMetaData40.java Fri Apr 28 11:41:07 2006
@@ -63,7 +63,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement.java Fri Apr 28 11:41:07 2006
@@ -182,7 +182,7 @@
 
             if (section_ == null) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.CURSOR_INVALID_CURSOR_NAME), cursorName);
+                    new ClientMessageId(SQLState.CURSOR_INVALID_CURSOR_NAME), cursorName);
             }
 
             //scrollableRS_ = agent_.sectionManager_.getPositionedUpdateResultSet (cursorName);
@@ -254,7 +254,7 @@
             agent_.logWriter_.traceEntry(this, "execute", sql);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "execute(String)").getSQLException();
     }
 
@@ -263,7 +263,7 @@
             agent_.logWriter_.traceEntry(this, "executeQuery", sql);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "executeQuery(String)").getSQLException();
     }
 
@@ -272,7 +272,7 @@
             agent_.logWriter_.traceEntry(this, "executeUpdate", sql);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "executeUpdate(String)").getSQLException();
     }
     // ---------------------------jdbc 1------------------------------------------
@@ -360,7 +360,7 @@
 
         if (!parameterMetaData_.nullable_[parameterIndex - 1]) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_NULL_INTO_NON_NULL),
+                new ClientMessageId(SQLState.LANG_NULL_INTO_NON_NULL),
                 new Integer(parameterIndex));
         }
         setInput(parameterIndex, null);
@@ -577,7 +577,7 @@
                 }
                 if (calendar == null) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_API_PARAMETER),
+                        new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                         "null", "calendar", "setDate");
                 }
                 java.util.Calendar targetCalendar = java.util.Calendar.getInstance(calendar.getTimeZone());
@@ -633,7 +633,7 @@
                 }
                 if (calendar == null) {
                     throw new SqlException(agent_.logWriter_,
-                        new MessageId(SQLState.INVALID_API_PARAMETER),
+                        new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                         "null", "calendar", "setTime()");
                 }
                 java.util.Calendar targetCalendar = java.util.Calendar.getInstance(calendar.getTimeZone());
@@ -692,7 +692,7 @@
                 }
                 if (calendar == null) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_API_PARAMETER),
+                        new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                         "null", "calendar", "setTimestamp()");
                 }
                 java.util.Calendar targetCalendar = java.util.Calendar.getInstance(calendar.getTimeZone());
@@ -938,7 +938,7 @@
                 }
                 parameterIndex = checkSetterPreconditions(parameterIndex);
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                    new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
             }
         }
         catch ( SqlException se )
@@ -956,7 +956,7 @@
                 }
                 parameterIndex = checkSetterPreconditions(parameterIndex);
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                    new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
             }
         }
         catch ( SqlException se )
@@ -1013,7 +1013,7 @@
                 } else {
                     checkSetterPreconditions(parameterIndex);
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.UNSUPPORTED_TYPE));
+                        new ClientMessageId(SQLState.UNSUPPORTED_TYPE));
                 }
             }
         }
@@ -1086,7 +1086,7 @@
             // Any problems with scale should have already been caught by
             // checkForvalidScale
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.JAVA_EXCEPTION),
+                new ClientMessageId(SQLState.JAVA_EXCEPTION),
                 new Object[] {ae.getClass().getName(), ae.getMessage()}, ae);
         }
         try { 
@@ -1239,7 +1239,7 @@
             agent_.logWriter_.traceEntry(this, "execute", sql, autoGeneratedKeys);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "execute(String, int)").getSQLException();
     }
 
@@ -1248,7 +1248,7 @@
             agent_.logWriter_.traceEntry(this, "execute", sql, columnNames);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "execute(String, String[])").getSQLException();
     }
 
@@ -1257,7 +1257,7 @@
             agent_.logWriter_.traceEntry(this, "execute", sql, columnIndexes);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "execute(String, int[])").getSQLException();
     }
 
@@ -1266,7 +1266,7 @@
             agent_.logWriter_.traceEntry(this, "executeUpdate", autoGeneratedKeys);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "executeUpdate(String, int)").getSQLException();
     }
 
@@ -1275,7 +1275,7 @@
             agent_.logWriter_.traceEntry(this, "executeUpdate", columnNames);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "executeUpdate(String, String[])").getSQLException();
     }
 
@@ -1284,7 +1284,7 @@
             agent_.logWriter_.traceEntry(this, "executeUpdate", columnIndexes);
         }
         throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
+            new ClientMessageId(SQLState.NOT_FOR_PREPARED_STATEMENT),
             "execute(String, int[])").getSQLException();
     }
 
@@ -1725,7 +1725,7 @@
             // Throw an exception if holdability returned by the server is different from requested.
             if (resultSet_ != null && resultSet_.resultSetHoldability_ != resultSetHoldability_ && sqlMode_ != isCall__) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.UNABLE_TO_OPEN_RESULTSET_WITH_REQUESTED_HOLDABILTY),
+                    new ClientMessageId(SQLState.UNABLE_TO_OPEN_RESULTSET_WITH_REQUESTED_HOLDABILTY),
                         new Integer(resultSetHoldability_));
             }
     }
@@ -1763,7 +1763,7 @@
 		// that imposes an upper limit on the batch size we can support:
 		if (batchSize > 65534)
             throw new BatchUpdateException(agent_.logWriter_, 
-                new MessageId(SQLState.TOO_MANY_COMMANDS_FOR_BATCH), 
+                new ClientMessageId(SQLState.TOO_MANY_COMMANDS_FOR_BATCH), 
                 new Integer(65534), updateCounts);
 
         // Initialize all the updateCounts to indicate failure
@@ -1775,11 +1775,11 @@
 
         if (!supportsQueryBatchRequest && sqlMode_ == isQuery__) {
             throw new BatchUpdateException(agent_.logWriter_, 
-                new MessageId(SQLState.CANNOT_BATCH_QUERIES), updateCounts);
+                new ClientMessageId(SQLState.CANNOT_BATCH_QUERIES), updateCounts);
         }
         if (supportsQueryBatchRequest && sqlMode_ != isQuery__) {
             throw new BatchUpdateException(agent_.logWriter_, 
-                new MessageId(SQLState.QUERY_BATCH_ON_NON_QUERY_STATEMENT), 
+                new ClientMessageId(SQLState.QUERY_BATCH_ON_NON_QUERY_STATEMENT), 
                 updateCounts);
         }
 
@@ -1825,7 +1825,7 @@
             } else if (outputRegistered_) // make sure no output parameters are registered
             {
                 throw new BatchUpdateException(agent_.logWriter_, 
-                    new MessageId(SQLState.OUTPUT_PARAMS_NOT_ALLOWED),
+                    new ClientMessageId(SQLState.OUTPUT_PARAMS_NOT_ALLOWED),
                     updateCounts);
             } else {
                 writeExecuteCall(false, // no output expected for batched CALLs
@@ -1945,7 +1945,7 @@
     void checkForValidParameterIndex(int parameterIndex) throws SqlException {
         if (parameterMetaData_ == null || parameterIndex < 1 || parameterIndex > parameterMetaData_.columns_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_PARAM_POSITION),
+                new ClientMessageId(SQLState.LANG_INVALID_PARAM_POSITION),
                 new Integer(parameterIndex), 
                 new Integer(parameterMetaData_.columns_));
         }
@@ -1956,7 +1956,7 @@
             for (int i = 0; i < parameterMetaData_.columns_; i++) {
                 if (!parameterSet_[i] && !parameterRegistered_[i]) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.LANG_MISSING_PARMS));
+                        new ClientMessageId(SQLState.LANG_MISSING_PARMS));
                 }
             }
         }
@@ -1967,7 +1967,7 @@
         if (escapedProcedureCallWithResult_) {
             if (parameterIndex == 1) {
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.LANG_RETURN_OUTPUT_PARAM_CANNOT_BE_SET));
+                    new ClientMessageId(SQLState.LANG_RETURN_OUTPUT_PARAM_CANNOT_BE_SET));
             } else {
                 parameterIndex--;
             }
@@ -1978,7 +1978,7 @@
     void checkForValidScale(int scale) throws SqlException {
         if (scale < 0 || scale > 31) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.BAD_SCALE_VALUE),
+                new ClientMessageId(SQLState.BAD_SCALE_VALUE),
                 new Integer(scale));
         }
     }
@@ -1999,7 +1999,7 @@
             if ((32 - scaleDifference) < inputLength) {
                 // TODO - FINISH THIS
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.REGOUTPARAM_SCALE_DOESNT_MATCH_SETTER));
+                    new ClientMessageId(SQLState.REGOUTPARAM_SCALE_DOESNT_MATCH_SETTER));
             }
             // if the new Decimal (with bigger scale) can fit
             else {
@@ -2017,7 +2017,7 @@
             } catch (ArithmeticException e) {
                 // if the new Decimal (with smaller scale) cannot fit into the DA
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.REGOUTPARAM_SCALE_DOESNT_MATCH_SETTER));
+                    new ClientMessageId(SQLState.REGOUTPARAM_SCALE_DOESNT_MATCH_SETTER));
             }
         }
     }
@@ -2068,7 +2068,7 @@
             }
             if(length > Integer.MAX_VALUE)
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.BLOB_TOO_LARGE_FOR_CLIENT),
+                    new ClientMessageId(SQLState.BLOB_TOO_LARGE_FOR_CLIENT),
                     new Long(length), new Integer(Integer.MAX_VALUE)).getSQLException();
             else
                 setInput(parameterIndex, new Clob(agent_, reader, (int)length));
@@ -2099,7 +2099,7 @@
             }
             if(length > Integer.MAX_VALUE)
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.BLOB_TOO_LARGE_FOR_CLIENT),
+                    new ClientMessageId(SQLState.BLOB_TOO_LARGE_FOR_CLIENT),
                     new Long(length), new Integer(Integer.MAX_VALUE)).getSQLException();
             else {
                 try {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/PreparedStatement40.java Fri Apr 28 11:41:07 2006
@@ -27,7 +27,7 @@
 import java.io.Reader;
 import java.io.InputStream;
 import org.apache.derby.client.am.SqlException;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
 public class  PreparedStatement40 extends  org.apache.derby.client.am.PreparedStatement{
@@ -106,7 +106,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/ResultSet.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/ResultSet.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/ResultSet.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/ResultSet.java Fri Apr 28 11:41:07 2006
@@ -235,7 +235,7 @@
             statement_.accumulateWarning(
                 new SqlWarning(
                     agent_.logWriter_, 
-                    new MessageId(SQLState.INVALID_RESULTSET_TYPE),
+                    new ClientMessageId(SQLState.INVALID_RESULTSET_TYPE),
                         new Integer(statement_.resultSetType_),
                         new Integer(resultSetType_)));
         }
@@ -248,7 +248,7 @@
             accumulateWarning(
                 new SqlWarning(
                     agent_.logWriter_,
-                    new MessageId(
+                    new ClientMessageId(
                     SQLState.QUERY_NOT_QUALIFIED_FOR_UPDATABLE_RESULTSET)));
                 
         }
@@ -530,7 +530,7 @@
 
             if (wasNull_ == ResultSet.WAS_NULL_UNSET) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.WASNULL_INVALID));
+                    new ClientMessageId(SQLState.WASNULL_INVALID));
             }
 
             if (agent_.loggingEnabled()) {
@@ -885,7 +885,7 @@
             }
             if (calendar == null) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.CALENDAR_IS_NULL));
+                    new ClientMessageId(SQLState.CALENDAR_IS_NULL));
             }
             java.sql.Date date = getDate(column);
             if (date != null) {
@@ -950,7 +950,7 @@
             }
             if (calendar == null) {
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.CALENDAR_IS_NULL));
+                    new ClientMessageId(SQLState.CALENDAR_IS_NULL));
             }
             java.sql.Time time = getTime(column);
             if (time != null) {
@@ -1015,7 +1015,7 @@
             }
             if (calendar == null) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.CALENDAR_IS_NULL));
+                    new ClientMessageId(SQLState.CALENDAR_IS_NULL));
             }
             java.sql.Timestamp timestamp = getTimestamp(column);
             if (timestamp != null) {
@@ -1184,7 +1184,7 @@
                                     updatedColumns_[column - 1])).getBytes("UTF-8"));
                 } catch (java.io.UnsupportedEncodingException e) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.UNSUPPORTED_ENCODING),
+                        new ClientMessageId(SQLState.UNSUPPORTED_ENCODING),
                         "String", "java.io.ByteArrayInputStream(UTF-8)", e);
                 }
             } else {
@@ -1305,7 +1305,7 @@
             java.sql.Ref result = isNull(column) ? null : cursor_.getRef(column);
             if (true) {
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                    new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
             }
             if (agent_.loggingEnabled()) {
                 agent_.logWriter_.traceExit(this, "getRef", result);
@@ -1332,7 +1332,7 @@
             java.sql.Array result = isNull(column) ? null : cursor_.getArray(column);
             if (true) {
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                    new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
             }
             if (agent_.loggingEnabled()) {
                 agent_.logWriter_.traceExit(this, "getArray", result);
@@ -1398,7 +1398,7 @@
             }
             if (true) {
                 throw new SqlException(agent_.logWriter_,
-                    new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                    new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
             }
             if (agent_.loggingEnabled()) {
                 agent_.logWriter_.traceExit(this, "getObject", result);
@@ -2328,7 +2328,7 @@
         }
         if (row > Integer.MAX_VALUE) {
             this.accumulateWarning(new SqlWarning(agent_.logWriter_, 
-                new MessageId(SQLState.NUMBER_OF_ROWS_TOO_LARGE_FOR_INT),
+                new ClientMessageId(SQLState.NUMBER_OF_ROWS_TOO_LARGE_FOR_INT),
                 new Long(row)));
         }
         return (int) row;
@@ -2451,7 +2451,7 @@
         // this method may not be called when the cursor on the insert row
         if (isOnInsertRow_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
         }
 
         // If the resultset is empty, relative(n) is a null operation
@@ -2628,7 +2628,7 @@
                     break;
                 default:
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_FETCH_DIRECTION),
+                        new ClientMessageId(SQLState.INVALID_FETCH_DIRECTION),
                         new Integer(direction));
                 }
             }
@@ -2664,7 +2664,7 @@
                 checkForClosedResultSet();
                 if (rows < 0 || (maxRows_ != 0 && rows > maxRows_)) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_FETCH_SIZE),
+                        new ClientMessageId(SQLState.INVALID_FETCH_SIZE),
                         new Integer(rows)).getSQLException();
                 }
                 setFetchSize_(rows);
@@ -2789,7 +2789,7 @@
                 checkUpdatePreconditions(column, "updateNull");
                 if (!resultSetMetaData_.nullable_[column - 1]) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.LANG_NULL_INTO_NON_NULL),
+                        new ClientMessageId(SQLState.LANG_NULL_INTO_NON_NULL),
                         new Integer(column));
                 }
                 updateColumn(column, null);
@@ -3410,13 +3410,13 @@
 	checkForUpdatableResultSet("insertRow");
         if (isOnCurrentRow_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
+                new ClientMessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
        }
  
         // if not on a valid row, then do not accept updateXXX calls
         if (!isValidCursorPosition_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
         }
 
         // User might not be updating all the updatable columns selected in the
@@ -3483,13 +3483,13 @@
         
         if (isOnInsertRow_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
+                new ClientMessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
         }
 
         //if not on a valid row, then do not accept updateXXX calls
         if (!isValidCursorPosition_)
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
 
         // If no updateXXX has been called on this ResultSet object, then
         // updatedColumns_ will be null and hence no action required
@@ -3609,7 +3609,7 @@
 
         if (isOnInsertRow_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
+                new ClientMessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
         }
 
         if (preparedStatementForDelete_ == null) {
@@ -3655,7 +3655,7 @@
 	checkForUpdatableResultSet("refreshRow");
         if (isBeforeFirstX() || isAfterLastX() || isOnInsertRow_) {
             throw new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.CURSOR_CANNOT_INVOKE_ON_INSROW_OR_INVALIDROW_OR_READONLY));
+                new ClientMessageId(SQLState.CURSOR_CANNOT_INVOKE_ON_INSROW_OR_INVALIDROW_OR_READONLY));
         }
 	
         // this method does nothing if ResultSet is TYPE_SCROLL_INSENSITIVE
@@ -3683,13 +3683,13 @@
                 checkForUpdatableResultSet("cancelRowUpdates");
                 if (isOnInsertRow_) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
+                        new ClientMessageId(SQLState.CURSOR_NOT_POSITIONED_ON_INSERT_ROW));
                 }
 
                 // if not on a valid row, then do not accept cancelRowUpdates call
                 if (!isValidCursorPosition_)
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                        new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
 
                 // if updateRow() has already been called, then cancelRowUpdates should have
                 // no effect.  updateRowCalled_ is reset to false as soon as the cursor moves to a new row.
@@ -4510,7 +4510,7 @@
 
         if (updateString == null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_NO_UPDATE_CALLS_ON_CURRENT_ROW));
+                new ClientMessageId(SQLState.CURSOR_NO_UPDATE_CALLS_ON_CURRENT_ROW));
         }
         preparedStatementForUpdate_ =
                 statement_.connection_.preparePositionedUpdateStatement(updateString,
@@ -4577,24 +4577,24 @@
 
         if (!isOnCurrentRow_ && !isOnInsertRow_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_NOT_ON_CURRENT_OR_INSERT_ROW));
+                new ClientMessageId(SQLState.CURSOR_NOT_ON_CURRENT_OR_INSERT_ROW));
         }
 
         if (resultSetMetaData_.sqlxUpdatable_ == null || resultSetMetaData_.sqlxUpdatable_[column - 1] != 1) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_COLUMN_NOT_UPDATABLE));
+                new ClientMessageId(SQLState.CURSOR_COLUMN_NOT_UPDATABLE));
         }
 
         //if not on a valid row, then do not accept updateXXX calls
         if (!isValidCursorPosition_)
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
     }
 
     final void checkForValidColumnIndex(int column) throws SqlException {
         if (column < 1 || column > resultSetMetaData_.columns_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_COLUMN_POSITION),
+                new ClientMessageId(SQLState.LANG_INVALID_COLUMN_POSITION),
                 new Integer(column), new Integer(resultSetMetaData_.columns_));
         }
     }
@@ -4603,7 +4603,7 @@
         if (!openOnClient_) {
             agent_.checkForDeferredExceptions();
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CLIENT_RESULT_SET_NOT_OPEN));
+                new ClientMessageId(SQLState.CLIENT_RESULT_SET_NOT_OPEN));
         } else {
             agent_.checkForDeferredExceptions();
         }
@@ -4613,7 +4613,7 @@
         throws SqlException {
         if (resultSetConcurrency_ == java.sql.ResultSet.CONCUR_READ_ONLY) {
             throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.UPDATABLE_RESULTSET_API_DISALLOWED),
+                    new ClientMessageId(SQLState.UPDATABLE_RESULTSET_API_DISALLOWED),
                     operation);
         }
     }
@@ -4621,21 +4621,21 @@
     private final void checkForValidCursorPosition() throws SqlException {
         if (!isValidCursorPosition_) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
+                new ClientMessageId(SQLState.CURSOR_INVALID_OPERATION_AT_CURRENT_POSITION));
         }
     }
 
     private final void checkThatResultSetTypeIsScrollable() throws SqlException {
         if (resultSetType_ == java.sql.ResultSet.TYPE_FORWARD_ONLY) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_MUST_BE_SCROLLABLE));
+                new ClientMessageId(SQLState.CURSOR_MUST_BE_SCROLLABLE));
         }
     }
 
     private final void checkThatResultSetIsNotDynamic() throws SqlException {
         if (sensitivity_ == sensitivity_sensitive_dynamic__) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CURSOR_INVALID_FOR_SENSITIVE_DYNAMIC));
+                new ClientMessageId(SQLState.CURSOR_INVALID_FOR_SENSITIVE_DYNAMIC));
         }
     }
 
@@ -5301,7 +5301,7 @@
 				
 			}catch(IOException e){				
 				throw new SqlException(agent_.logWriter_ ,
-                    new MessageId(SQLState.JAVA_EXCEPTION), 
+                    new ClientMessageId(SQLState.JAVA_EXCEPTION), 
                     "java.io.IOException", e.getMessage(), e);
 			}
 			
@@ -5315,7 +5315,7 @@
 	
 	if(streamUsedFlags_[columnIndex - 1]){
 	    throw new SqlException(agent_.logWriter_,
-            new MessageId(SQLState.LANG_STREAM_RETRIEVED_ALREADY));
+            new ClientMessageId(SQLState.LANG_STREAM_RETRIEVED_ALREADY));
 	}
 
 	streamUsedFlags_[columnIndex - 1] = true;

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/SQLExceptionFactory.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/SQLExceptionFactory.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/SQLExceptionFactory.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/SQLExceptionFactory.java Fri Apr 28 11:41:07 2006
@@ -31,7 +31,7 @@
      
     public static SQLException notImplemented (String feature) {
         SqlException sqlException = new SqlException (null, 
-                new MessageId (SQLState.NOT_IMPLEMENTED), feature);
+                new ClientMessageId (SQLState.NOT_IMPLEMENTED), feature);
         return sqlException.getSQLException();
     }
     

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/Savepoint.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/Savepoint.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/Savepoint.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/Savepoint.java Fri Apr 28 11:41:07 2006
@@ -52,7 +52,7 @@
             return savepointId_;
         } else {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NO_ID_FOR_NAMED_SAVEPOINT)).getSQLException();
+                new ClientMessageId(SQLState.NO_ID_FOR_NAMED_SAVEPOINT)).getSQLException();
         }
     }
 
@@ -61,7 +61,7 @@
             return savepointName_;
         } else {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NO_NAME_FOR_UNNAMED_SAVEPOINT)).getSQLException();
+                new ClientMessageId(SQLState.NO_NAME_FOR_UNNAMED_SAVEPOINT)).getSQLException();
         }
     }
 }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/SectionManager.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/SectionManager.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/SectionManager.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/SectionManager.java Fri Apr 28 11:41:07 2006
@@ -119,7 +119,7 @@
             return getSection(freeSectionsNonHold_, packageNameWithNoHold__, cursorNamePrefixWithNoHold__, resultSetHoldability);
         } else {
             throw new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.UNSUPPORTED_HOLDABILITY_PROPERTY), 
+                new ClientMessageId(SQLState.UNSUPPORTED_HOLDABILITY_PROPERTY), 
                 new Integer(resultSetHoldability));
         }
     }
@@ -136,7 +136,7 @@
         // unfortunately we have run out of sections
         {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.EXCEEDED_MAX_SECTIONS),
+                new ClientMessageId(SQLState.EXCEEDED_MAX_SECTIONS),
                 "32k");
         }
     }
@@ -190,7 +190,7 @@
         ResultSet rs = (ResultSet) positionedUpdateCursorNameToResultSet_.get(cursorName);
         if (rs == null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CLIENT_RESULT_SET_NOT_OPEN));
+                new ClientMessageId(SQLState.CLIENT_RESULT_SET_NOT_OPEN));
         }
         return (rs.resultSetType_ == java.sql.ResultSet.TYPE_FORWARD_ONLY) ? null : rs;
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlException.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlException.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlException.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlException.java Fri Apr 28 11:41:07 2006
@@ -116,7 +116,7 @@
     // The message id is wrapped inside a class so that we can distinguish
     // between the signatures of the new constructors and the old constructors
     public SqlException(LogWriter logwriter, 
-        MessageId msgid, Object[] args, Throwable cause)
+        ClientMessageId msgid, Object[] args, Throwable cause)
     {
         this(
             logwriter,
@@ -135,66 +135,66 @@
      * Use this to override the standard error code that is derived
      * from the message severity
      */
-    public SqlException(LogWriter logWriter, MessageId msgid, Object[] args,
+    public SqlException(LogWriter logWriter, ClientMessageId msgid, Object[] args,
         SqlCode sqlcode) {
         this(logWriter, msgid, args);
         this.errorcode_ = sqlcode.getCode();
     }
         
-    public SqlException(LogWriter logWriter, MessageId msgid, SqlCode sqlcode) {
+    public SqlException(LogWriter logWriter, ClientMessageId msgid, SqlCode sqlcode) {
         this(logWriter, msgid, (Object[])null, sqlcode);
     }
     
-    public SqlException(LogWriter logWriter, MessageId msgid, Object arg1,
+    public SqlException(LogWriter logWriter, ClientMessageId msgid, Object arg1,
         SqlCode sqlcode) {
         this(logWriter, msgid, new Object[] {arg1}, sqlcode);
     }
         
-    public SqlException(LogWriter logWriter, MessageId msgid, Object arg1,
+    public SqlException(LogWriter logWriter, ClientMessageId msgid, Object arg1,
         Object arg2, SqlCode sqlcode) {
         this(logWriter, msgid, new Object[] {arg1, arg2}, sqlcode);
     }
  
     public SqlException (LogWriter logwriter, 
-            MessageId msgid, Throwable cause) {
+            ClientMessageId msgid, Throwable cause) {
         this (logwriter, msgid, (Object[])null, cause);
     }
     
-    public SqlException(LogWriter logwriter, MessageId msgid, Object[] args)
+    public SqlException(LogWriter logwriter, ClientMessageId msgid, Object[] args)
     {
         this(logwriter, msgid, args, (Throwable)null);
     }
     
-    public SqlException (LogWriter logwriter, MessageId msgid)
+    public SqlException (LogWriter logwriter, ClientMessageId msgid)
     {
         this(logwriter, msgid, (Object[])null);
     }
     
-    public SqlException(LogWriter logwriter, MessageId msgid, Object arg1)
+    public SqlException(LogWriter logwriter, ClientMessageId msgid, Object arg1)
     {
         this(logwriter, msgid, new Object[] { arg1 });
     }
     
-    public SqlException(LogWriter logwriter, MessageId msgid, 
+    public SqlException(LogWriter logwriter, ClientMessageId msgid, 
             Object arg1, Throwable cause)
     {
         this(logwriter, msgid, new Object[] { arg1 }, cause);
     }
     
-    public SqlException(LogWriter logwriter, MessageId msgid,
+    public SqlException(LogWriter logwriter, ClientMessageId msgid,
         Object arg1, Object arg2, Throwable cause)
     {
         this(logwriter, msgid, new Object[] { arg1, arg2 }, cause);
     }
     
     public SqlException(LogWriter logwriter,
-        MessageId msgid, Object arg1, Object arg2)
+        ClientMessageId msgid, Object arg1, Object arg2)
     {
         this(logwriter, msgid, new Object[] { arg1, arg2 });
     }
     
     public SqlException(LogWriter logwriter,
-        MessageId msgid, Object arg1, Object arg2, Object arg3)
+        ClientMessageId msgid, Object arg1, Object arg2, Object arg3)
     {
         this(logwriter, msgid, new Object[] { arg1, arg2, arg3 });
     }
@@ -473,7 +473,7 @@
      */
     public static SqlException javaException(LogWriter logWriter, Throwable e) {
         return new SqlException(logWriter, 
-            new MessageId (SQLState.JAVA_EXCEPTION), 
+            new ClientMessageId (SQLState.JAVA_EXCEPTION), 
             new Object[] {e.getClass().getName(), e.getMessage()}, e);
     }
     
@@ -504,7 +504,7 @@
     ColumnTypeConversionException(LogWriter logWriter, String sourceType,
         String targetType) {
         super(logWriter,
-            new MessageId(SQLState.LANG_DATA_TYPE_GET_MISMATCH),
+            new ClientMessageId(SQLState.LANG_DATA_TYPE_GET_MISMATCH),
             sourceType, targetType);
     }
 }
@@ -514,7 +514,7 @@
 
 class LossOfPrecisionConversionException extends SqlException {
     LossOfPrecisionConversionException(LogWriter logWriter, String instance) {
-        super(logWriter, new MessageId(SQLState.LOSS_OF_PRECISION_EXCEPTION), 
+        super(logWriter, new ClientMessageId(SQLState.LOSS_OF_PRECISION_EXCEPTION), 
             instance);
     }
 }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlWarning.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlWarning.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlWarning.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/SqlWarning.java Fri Apr 28 11:41:07 2006
@@ -36,34 +36,34 @@
     protected SqlWarning nextWarning_;
     
     public SqlWarning(LogWriter logwriter, 
-        MessageId msgid, Object[] args, Throwable cause)
+        ClientMessageId msgid, Object[] args, Throwable cause)
     {
         super(logwriter, msgid, args, cause);
     }
     
-    public SqlWarning(LogWriter logwriter, MessageId msgid, Object[] args)
+    public SqlWarning(LogWriter logwriter, ClientMessageId msgid, Object[] args)
     {
         this(logwriter, msgid, args, null);
     }
     
-    public SqlWarning (LogWriter logwriter, MessageId msgid)
+    public SqlWarning (LogWriter logwriter, ClientMessageId msgid)
     {
         super(logwriter, msgid);
     }
     
-    public SqlWarning(LogWriter logwriter, MessageId msgid, Object arg1)
+    public SqlWarning(LogWriter logwriter, ClientMessageId msgid, Object arg1)
     {
         super(logwriter, msgid, arg1);
     }
     
     public SqlWarning(LogWriter logwriter,
-        MessageId msgid, Object arg1, Object arg2)
+        ClientMessageId msgid, Object arg1, Object arg2)
     {
         super(logwriter, msgid, arg1, arg2);
     }
     
     public SqlWarning(LogWriter logwriter,
-        MessageId msgid, Object arg1, Object arg2, Object arg3)
+        ClientMessageId msgid, Object arg1, Object arg2, Object arg3)
     {
         super(logwriter, msgid, arg1, arg2, arg3);
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/Sqlca.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/Sqlca.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/Sqlca.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/Sqlca.java Fri Apr 28 11:41:07 2006
@@ -283,12 +283,12 @@
             current = current.copyAsUnchainedSQLException(agent_.logWriter_);
             if (current.getErrorCode() == -440) {
                 SqlWarning warningForStoredProcFailure = new SqlWarning(agent_.logWriter_,
-                    new MessageId(SQLState.UNABLE_TO_OBTAIN_MESSAGE_TEXT_FROM_SERVER));
+                    new ClientMessageId(SQLState.UNABLE_TO_OBTAIN_MESSAGE_TEXT_FROM_SERVER));
                 warningForStoredProcFailure.setNextException(current.getSQLException());
                 connection_.accumulate440WarningForMessageProcFailure(warningForStoredProcFailure);
             } else if (current.getErrorCode() == -444) {
                 SqlWarning warningForStoredProcFailure = new SqlWarning(agent_.logWriter_,
-                    new MessageId(SQLState.UNABLE_TO_OBTAIN_MESSAGE_TEXT_FROM_SERVER));
+                    new ClientMessageId(SQLState.UNABLE_TO_OBTAIN_MESSAGE_TEXT_FROM_SERVER));
                 warningForStoredProcFailure.setNextException(current.getSQLException());
                 connection_.accumulate444WarningForMessageProcFailure(warningForStoredProcFailure);
             } else {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement.java Fri Apr 28 11:41:07 2006
@@ -323,7 +323,7 @@
             break;
         default:
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.INVALID_API_PARAMETER),
+                new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                 new Integer(type), "type", "createStatement()");
         }
 
@@ -334,7 +334,7 @@
             break;
         default:
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.INVALID_API_PARAMETER),
+                new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                 new Integer(concurrency), "concurrency",
                 "createStatement()");
         }
@@ -346,7 +346,7 @@
             break;
         default:
             throw new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.INVALID_API_PARAMETER),
+                new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                 new Integer(holdability), "holdability",
                 "createStatement()");
         }
@@ -358,7 +358,7 @@
             break;
         default:
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.INVALID_API_PARAMETER),
+                new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                 new Integer(autoGeneratedKeys),
                 "autoGeneratedKeys", "createStatement");
         }
@@ -424,13 +424,13 @@
         // We'll just rely on finalizers to close the dangling result sets.
         if (resultSetList_ != null && resultSetList_.length != 1) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.MULTIPLE_RESULTS_ON_EXECUTE_QUERY),
+                new ClientMessageId(SQLState.MULTIPLE_RESULTS_ON_EXECUTE_QUERY),
                 jdbcStatementInterfaceName, jdbcStatementInterfaceName);
         }
 
         if (resultSet_ == null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.USE_EXECUTE_UPDATE_WITH_NO_RESULTS),
+                new ClientMessageId(SQLState.USE_EXECUTE_UPDATE_WITH_NO_RESULTS),
                 jdbcStatementInterfaceName, jdbcStatementInterfaceName);
         }
     }
@@ -466,14 +466,14 @@
         // We'll just rely on finalizers to close the dangling result sets.
         if (resultSetList_ != null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.MULTIPLE_RESULTS_ON_EXECUTE_QUERY),
+                new ClientMessageId(SQLState.MULTIPLE_RESULTS_ON_EXECUTE_QUERY),
                 jdbcStatementInterfaceName, jdbcStatementInterfaceName);
         }
 
         // We'll just rely on the finalizer to close the dangling result set.
         if (resultSet_ != null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_CALL_TO_EXECUTE_UPDATE));
+                new ClientMessageId(SQLState.LANG_INVALID_CALL_TO_EXECUTE_UPDATE));
         }
     }
 
@@ -575,7 +575,7 @@
                 checkForClosedStatement();
                 if (max < 0) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_MAXFIELD_SIZE),
+                        new ClientMessageId(SQLState.INVALID_MAXFIELD_SIZE),
                         new Integer(max));
                 }
                 maxFieldSize_ = max;
@@ -612,7 +612,7 @@
                 checkForClosedStatement(); // Per jdbc spec (see java.sql.Statement.close() javadoc)
                 if (maxRows < 0) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_MAX_ROWS_VALUE),
+                        new ClientMessageId(SQLState.INVALID_MAX_ROWS_VALUE),
                         new Integer(maxRows));
                 }
                 maxRows_ = maxRows;
@@ -665,7 +665,7 @@
                 checkForClosedStatement(); // Per jdbc spec (see java.sql.Statement.close() javadoc)
                 if (seconds < 0) {
                     throw new SqlException(agent_.logWriter_,
-                        new MessageId(SQLState.INVALID_QUERYTIMEOUT_VALUE),
+                        new ClientMessageId(SQLState.INVALID_QUERYTIMEOUT_VALUE),
                         new Integer(seconds));
                 }
                 if (seconds != timeout_) {
@@ -688,7 +688,7 @@
             }
             checkForClosedStatement(); // Per jdbc spec (see java.sql.Statement.close() javadoc)
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CANCEL_NOT_SUPPORTED_BY_SERVER));
+                new ClientMessageId(SQLState.CANCEL_NOT_SUPPORTED_BY_SERVER));
         }
         catch ( SqlException se )
         {
@@ -732,21 +732,21 @@
                 checkForClosedStatement(); // Per jdbc spec (see java.sql.Statement.close() javadoc)
                 if (name == null || name.equals("")) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.CURSOR_INVALID_NAME),
+                        new ClientMessageId(SQLState.CURSOR_INVALID_NAME),
                         name);
                 }
 
                 // Invalid to set the cursor name if there are ResultSet's open on the Statement.
                 if (resultSet_ != null && resultSet_.openOnClient_) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.LANG_CANT_INVALIDATE_OPEN_RESULT_SET),
+                        new ClientMessageId(SQLState.LANG_CANT_INVALIDATE_OPEN_RESULT_SET),
                         "setCursorName()", "Statement");
                 }
 
                 // Duplicate cursor names not allowed.
                 if (connection_.clientCursorNameCache_.containsKey(name)) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.CURSOR_DUPLICATE_NAME), name);
+                        new ClientMessageId(SQLState.CURSOR_DUPLICATE_NAME), name);
                 }
                 connection_.clientCursorNameCache_.put(name, name);
 
@@ -874,7 +874,7 @@
                     break;
                 default:
                     throw new SqlException(agent_.logWriter_,
-                        new MessageId(SQLState.INVALID_FETCH_DIRECTION),
+                        new ClientMessageId(SQLState.INVALID_FETCH_DIRECTION),
                         new Integer(direction));
                 }
             }
@@ -911,7 +911,7 @@
 
                 if (rows < 0 || (maxRows_ != 0 && rows > maxRows_)) {
                     throw new SqlException(agent_.logWriter_, 
-                        new MessageId(SQLState.INVALID_ST_FETCH_SIZE),
+                        new ClientMessageId(SQLState.INVALID_ST_FETCH_SIZE),
                         new Integer(rows)).getSQLException();
                 }
                 fetchSize_ = rows;
@@ -1160,7 +1160,7 @@
             }
             checkForClosedStatement();
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NOT_IMPLEMENTED),
+                new ClientMessageId(SQLState.NOT_IMPLEMENTED),
                 "executeUpdate(String, int[])");
         }
         catch ( SqlException se )
@@ -1219,7 +1219,7 @@
             }
             checkForClosedStatement();
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NOT_IMPLEMENTED),
+                new ClientMessageId(SQLState.NOT_IMPLEMENTED),
                 "execute(String, int[])");
         }
         catch ( SqlException se )
@@ -1859,7 +1859,7 @@
                     newSection = agent_.sectionManager_.getPositionedUpdateSection(cursorName, true); // true means get an execute immediate section
                     if (newSection == null) {
                         throw new SqlException(agent_.logWriter_, 
-                            new MessageId(SQLState.CURSOR_INVALID_NAME),
+                            new ClientMessageId(SQLState.CURSOR_INVALID_NAME),
                             cursorName);
                     }
                     scrollableRS = agent_.sectionManager_.getPositionedUpdateResultSet(cursorName);
@@ -2000,7 +2000,7 @@
             // Throw an exception if holdability returned by the server is different from requested.
             if (resultSet_ != null && resultSet_.resultSetHoldability_ != resultSetHoldability_ && sqlMode_ != isCall__) {
                 throw new SqlException(agent_.logWriter_, 
-                    new MessageId(SQLState.UNABLE_TO_OPEN_RS_WITH_REQUESTED_HOLDABILITY),
+                    new ClientMessageId(SQLState.UNABLE_TO_OPEN_RS_WITH_REQUESTED_HOLDABILITY),
                     new Integer(resultSetHoldability_));
             }
 
@@ -2099,7 +2099,7 @@
         catch (SqlException e) {
             chainBreaker = e;
             chainBreaker.setNextException(new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.BATCH_CHAIN_BREAKING_EXCEPTION)));
+                new ClientMessageId(SQLState.BATCH_CHAIN_BREAKING_EXCEPTION)));
         }
         // We need to clear the batch before any exception is thrown from agent_.endBatchedReadChain().
         batch_.clear();
@@ -2206,7 +2206,7 @@
 
         if (!tokenizer.hasMoreTokens()) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NO_TOKENS_IN_SQL_TEXT), sql);
+                new ClientMessageId(SQLState.NO_TOKENS_IN_SQL_TEXT), sql);
         }
 
         sqlUpdateMode_ = 0;
@@ -2242,16 +2242,16 @@
         java.util.StringTokenizer tokenizer = new java.util.StringTokenizer(sql, "\t\n\r\f= (?");
         if (!tokenizer.hasMoreTokens()) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NO_TOKENS_IN_SQL_TEXT), sql);
+                new ClientMessageId(SQLState.NO_TOKENS_IN_SQL_TEXT), sql);
         }
         String firstToken = tokenizer.nextToken();
         if (!firstToken.equalsIgnoreCase("call")) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_CALL_STATEMENT));
+                new ClientMessageId(SQLState.LANG_INVALID_CALL_STATEMENT));
         }
         if (!tokenizer.hasMoreTokens()) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_CALL_STATEMENT));
+                new ClientMessageId(SQLState.LANG_INVALID_CALL_STATEMENT));
         }
         return tokenizer.nextToken();
     }
@@ -2282,11 +2282,11 @@
     void checkForAppropriateSqlMode(int executeType, int sqlMode) throws SqlException {
         if (executeType == executeQueryMethod__ && sqlMode == isUpdate__) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.CANT_USE_EXEC_QUERY_FOR_UPDATE));
+                new ClientMessageId(SQLState.CANT_USE_EXEC_QUERY_FOR_UPDATE));
         }
         if (executeType == executeUpdateMethod__ && sqlMode == isQuery__) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_CALL_TO_EXECUTE_UPDATE));
+                new ClientMessageId(SQLState.LANG_INVALID_CALL_TO_EXECUTE_UPDATE));
         }
     }
 
@@ -2299,12 +2299,12 @@
         //
         if ( this.connection_ == null || this.connection_.isClosed() )
             throw new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.NO_CURRENT_CONNECTION));
+                new ClientMessageId(SQLState.NO_CURRENT_CONNECTION));
         
         if (!openOnClient_) {
             agent_.checkForDeferredExceptions();
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_STATEMENT_CLOSED_NO_REASON));
+                new ClientMessageId(SQLState.LANG_STATEMENT_CLOSED_NO_REASON));
         } else {
             agent_.checkForDeferredExceptions();
         }
@@ -2314,7 +2314,7 @@
     void checkForInvalidBatchedSql(String sql) throws SqlException {
         if (sql == null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NULL_SQL_TEXT));
+                new ClientMessageId(SQLState.NULL_SQL_TEXT));
         }
 
         if (sqlMode_ != isCall__
@@ -2325,7 +2325,7 @@
                 || sqlUpdateMode_ == 0)))// For any undefined pass thru statement like drop create
         {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.LANG_INVALID_SQL_IN_BATCH), sql);
+                new ClientMessageId(SQLState.LANG_INVALID_SQL_IN_BATCH), sql);
         }
     }
 
@@ -2525,14 +2525,14 @@
         if (autoGeneratedKeys_ != java.sql.Statement.NO_GENERATED_KEYS &&
                 autoGeneratedKeys_ != java.sql.Statement.RETURN_GENERATED_KEYS) {
             throw new SqlException(agent_.logWriter_,
-                new MessageId(SQLState.INVALID_API_PARAMETER),
+                new ClientMessageId(SQLState.INVALID_API_PARAMETER),
                 new Integer(autoGeneratedKeys_), "autoGeneratedKeys",
                 "Statement.execute()/executeQuery()");
         }
 
         if (generatedKeysColumnNames_ != null) {
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.NOT_IMPLEMENTED),
+                new ClientMessageId(SQLState.NOT_IMPLEMENTED),
                 "Connection.prepareStatement(String sql, String[] columnNames)");
         }
     }
@@ -2635,7 +2635,7 @@
                 checkForClosedStatement();
             
             throw new SqlException(agent_.logWriter_, 
-                new MessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
+                new ClientMessageId(SQLState.JDBC_METHOD_NOT_IMPLEMENTED));
         }
         catch ( SqlException se )
         {

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/am/Statement40.java Fri Apr 28 11:41:07 2006
@@ -87,7 +87,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/EbcdicCcsidManager.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/net/EbcdicCcsidManager.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/EbcdicCcsidManager.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/EbcdicCcsidManager.java Fri Apr 28 11:41:07 2006
@@ -21,7 +21,7 @@
 package org.apache.derby.client.net;
 
 import org.apache.derby.client.am.SqlException;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
 /**
@@ -141,7 +141,7 @@
             // buffer[offset++] = (byte) 63;
             {
                 throw new SqlException(agent.logWriter_, 
-                    new MessageId(SQLState.CANT_CONVERT_UNICODE_TO_EBCDIC));
+                    new ClientMessageId(SQLState.CANT_CONVERT_UNICODE_TO_EBCDIC));
             } else {
                 buffer[offset++] = (byte) (conversionArrayToEbcdic[c]);
             }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnection40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnection40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnection40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetConnection40.java Fri Apr 28 11:41:07 2006
@@ -35,7 +35,7 @@
 import java.util.Properties;
 import org.apache.derby.impl.jdbc.Util;
 import org.apache.derby.jdbc.InternalDriver;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 
 public class  NetConnection40 extends org.apache.derby.client.net.NetConnection {
@@ -269,7 +269,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetDatabaseMetaData40.java Fri Apr 28 11:41:07 2006
@@ -23,7 +23,7 @@
 import java.sql.ResultSet;
 import java.sql.RowIdLifetime;
 import java.sql.SQLException;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.client.am.SQLExceptionFactory;
 import org.apache.derby.shared.common.reference.SQLState;
@@ -76,7 +76,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/NetResultSet40.java Fri Apr 28 11:41:07 2006
@@ -29,7 +29,7 @@
 import org.apache.derby.client.am.SQLExceptionFactory;
 import org.apache.derby.iapi.sql.ResultSet;
 import org.apache.derby.client.am.Cursor;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.shared.common.reference.SQLState;
 
@@ -174,7 +174,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/client/net/Request.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/client/net/Request.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/client/net/Request.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/client/net/Request.java Fri Apr 28 11:41:07 2006
@@ -21,7 +21,7 @@
 
 import org.apache.derby.client.am.DisconnectException;
 import org.apache.derby.client.am.EncryptionManager;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.client.am.Utils;
 import org.apache.derby.shared.common.reference.SQLState;
@@ -1534,7 +1534,7 @@
             offset_ += 10;
         } catch (java.io.UnsupportedEncodingException e) {
             throw new SqlException(netAgent_.logWriter_, 
-                    new MessageId(SQLState.UNSUPPORTED_ENCODING),
+                    new ClientMessageId(SQLState.UNSUPPORTED_ENCODING),
                     "java.sql.Date", "DATE", e);
         }
     }
@@ -1546,7 +1546,7 @@
             offset_ += 8;
         } catch(UnsupportedEncodingException e) {
             throw new SqlException(netAgent_.logWriter_, 
-                    new MessageId(SQLState.UNSUPPORTED_ENCODING),
+                    new ClientMessageId(SQLState.UNSUPPORTED_ENCODING),
                     "java.sql.Time", "TIME", e);
       }
     }
@@ -1558,7 +1558,7 @@
             offset_ += 26;
         }catch(UnsupportedEncodingException e) {
             throw new SqlException(netAgent_.logWriter_,  
-                    new MessageId(SQLState.UNSUPPORTED_ENCODING),
+                    new ClientMessageId(SQLState.UNSUPPORTED_ENCODING),
                     "java.sql.Timestamp", "TIMESTAMP", e);
         }
     }

Modified: db/derby/code/trunk/java/client/org/apache/derby/jdbc/ClientDataSource40.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/client/org/apache/derby/jdbc/ClientDataSource40.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/client/org/apache/derby/jdbc/ClientDataSource40.java (original)
+++ db/derby/code/trunk/java/client/org/apache/derby/jdbc/ClientDataSource40.java Fri Apr 28 11:41:07 2006
@@ -24,7 +24,7 @@
 import java.sql.QueryObjectFactory;
 import java.sql.QueryObjectGenerator;
 import java.sql.SQLException;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.client.am.SqlException;
 import org.apache.derby.shared.common.reference.SQLState;
 
@@ -155,7 +155,7 @@
         try { 
             return interfaces.cast(this);
         } catch (ClassCastException cce) {
-            throw new SqlException(null,new MessageId(SQLState.UNABLE_TO_UNWRAP),
+            throw new SqlException(null,new ClientMessageId(SQLState.UNABLE_TO_UNWRAP),
                     interfaces).getSQLException();
         }
     }

Added: db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/MessageId.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/MessageId.java?rev=397980&view=auto
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/MessageId.java (added)
+++ db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/MessageId.java Fri Apr 28 11:41:07 2006
@@ -0,0 +1,28 @@
+/*
+
+   Derby - Class org.apache.derby.iapi.reference.MessageId
+
+   Copyright 2000, 2004 The Apache Software Foundation or its licensors, as applicable.
+
+   Licensed 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.
+
+ */
+
+package org.apache.derby.iapi.reference;
+
+/**
+ * This class is a refactoring wrapper around the new location
+ * in shared/common/reference
+ */
+public interface MessageId extends org.apache.derby.shared.common.reference.MessageId {
+}

Propchange: db/derby/code/trunk/java/engine/org/apache/derby/iapi/reference/MessageId.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SqlExceptionTest.java
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SqlExceptionTest.java?rev=397980&r1=397979&r2=397980&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SqlExceptionTest.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/derbynet/SqlExceptionTest.java Fri Apr 28 11:41:07 2006
@@ -20,7 +20,7 @@
 
 import org.apache.derbyTesting.functionTests.util.BaseTestCase;
 import org.apache.derby.client.am.SqlException;
-import org.apache.derby.client.am.MessageId;
+import org.apache.derby.client.am.ClientMessageId;
 import org.apache.derby.shared.common.reference.SQLState;
 import java.sql.SQLException;
 import java.io.IOException;
@@ -44,7 +44,7 @@
     public void testChainedException() {
         IOException ioe = new IOException("Test exception");
         SqlException sqle = new SqlException(null,
-            new MessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
+            new ClientMessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
             ioe);
         SQLException javae = sqle.getSQLException();
         
@@ -62,7 +62,7 @@
     public void testNextException() {
         SQLException nexte = new SQLException("test");
         SqlException sqle = new SqlException(null,
-            new MessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
+            new ClientMessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
             nexte);
         SQLException javae = sqle.getSQLException();
         
@@ -74,10 +74,10 @@
         // just as well as java.sql.SQLException
         SqlException internalException = 
             new SqlException(null, 
-                new MessageId("08000"));
+                new ClientMessageId("08000"));
         
         javae = new SqlException(null, 
-            new MessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
+            new ClientMessageId(SQLState.NOGETCONN_ON_CLOSED_POOLED_CONNECTION),
             internalException).getSQLException();
         
         assertNotNull(javae.getNextException());