public void setKeyColumns(int [] keys) throws SQLException {
      int numCols = 0;
      if (RowSetMD != null) {
         numCols = RowSetMD.getColumnCount();
         if (keys.length > numCols)
            throw new SQLException(resBundle.handleGetObject("cachedrowsetimpl.keycols").toString());
      }
      keyCols = new int[keys.length];
      for (int i = 0; i < keys.length; i++) {
         if (RowSetMD != null && (keys[i] <= 0 ||
             keys[i] > numCols)) {
            throw new SQLException(resBundle.handleGetObject("cachedrowsetimpl.invalidcol").toString() +
                keys[i]);
         }
         keyCols[i] = keys[i];
      }
   }
Sets this <code>StreamingRowSetImpl</code> object's
<code>keyCols</code> field with the given array of column
numbers, which forms a key for uniquely identifying a row
in this rowset.

@param keys an array of <code>int</code> indicating the
       columns that form a primary key for this
       <code>StreamingRowSetImpl</code> object; every
       element in the array must be greater than
       <code>0</code> and less than or equal to the number
       of columns in this rowset
@throws SQLException if any of the numbers in the
           given array is not valid for this rowset
@see #getKeyColumns
src/main/java/org/replicadb/rowset/StreamingRowSetImpl.java