com.microsoft.sqlserver.jdbc

## Class SQLServerResultSet42

- java.lang.Object
- - com.microsoft.sqlserver.jdbc.SQLServerResultSet
  - - com.microsoft.sqlserver.jdbc.SQLServerResultSet42

All Implemented Interfaces:
  ISQLServerResultSet, ISQLServerResultSet42, AutoCloseable, ResultSet, Wrapper

    public class SQLServerResultSet42
    extends SQLServerResultSet
    implements ISQLServerResultSet42

This class is separated from SQLServerResultSet class in order to resolve compiling error of missing Java 8 Types when running with Java 7. This class will be initialized instead of SQLServerResultSet when Java 8 and JDBC 4.2 are used.

### Field Summary

### Fields inherited from class com.microsoft.sqlserver.jdbc.SQLServerResultSet

`loggerExternal`

### Fields inherited from interface com.microsoft.sqlserver.jdbc.ISQLServerResultSet

`CONCUR_SS_OPTIMISTIC_CC, CONCUR_SS_OPTIMISTIC_CCVAL, CONCUR_SS_SCROLL_LOCKS, TYPE_SS_DIRECT_FORWARD_ONLY, TYPE_SS_SCROLL_DYNAMIC, TYPE_SS_SCROLL_KEYSET, TYPE_SS_SCROLL_STATIC, TYPE_SS_SERVER_CURSOR_FORWARD_ONLY`

### Fields inherited from interface java.sql.ResultSet

`CLOSE_CURSORS_AT_COMMIT, CONCUR_READ_ONLY, CONCUR_UPDATABLE, FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, HOLD_CURSORS_OVER_COMMIT, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE`

### Constructor Summary

Constructors
Constructor and Description
`SQLServerResultSet42(SQLServerStatement stmtIn)` Makes a new result set

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `updateObject(int index, Object obj, SQLType targetSqlType)`
`void` `updateObject(int index, Object obj, SQLType targetSqlType, int scale)`
`void` `updateObject(int index, Object obj, SQLType targetSqlType, int scale, boolean forceEncrypt)` Updates the designated column with an Object value.
`void` `updateObject(String columnName, Object obj, SQLType targetSqlType)`
`void` `updateObject(String columnName, Object obj, SQLType targetSqlType, int scale)`
`void` `updateObject(String columnName, Object obj, SQLType targetSqlType, int scale, boolean forceEncrypt)` Updates the designated column with an Object value.

### Methods inherited from class com.microsoft.sqlserver.jdbc.SQLServerResultSet

`absolute, afterLast, beforeFirst, cancelRowUpdates, clearWarnings, close, deleteRow, findColumn, first, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getBoolean, getByte, getByte, getBytes, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDate, getDateTime, getDateTime, getDateTime, getDateTime, getDateTimeOffset, getDateTimeOffset, getDouble, getDouble, getFetchDirection, getFetchSize, getFloat, getFloat, getHoldability, getInt, getInt, getLong, getLong, getMetaData, getMoney, getMoney, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getNString, getObject, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRow, getRowId, getRowId, getServerCursorId, getShort, getShort, getSmallDateTime, getSmallDateTime, getSmallDateTime, getSmallDateTime, getSmallMoney, getSmallMoney, getSQLXML, getSQLXML, getStatement, getString, getString, getTDSReader, getTime, getTime, getTime, getTime, getTimestamp, getTimestamp, getTimestamp, getTimestamp, getType, getUnicodeStream, getUnicodeStream, getUniqueIdentifier, getUniqueIdentifier, getURL, getURL, getWarnings, insertRow, isAfterLast, isBeforeFirst, isClosed, isFirst, isForwardOnly, isLast, isWrapperFor, last, moveToCurrentRow, moveToInsertRow, next, previous, refreshRow, relative, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, toString, unwrap, updateArray, updateArray, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateBigDecimal, updateBigDecimal, updateBigDecimal, updateBigDecimal, updateBigDecimal, updateBigDecimal, updateBigDecimal, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBoolean, updateBoolean, updateBoolean, updateBoolean, updateByte, updateByte, updateByte, updateByte, updateBytes, updateBytes, updateBytes, updateBytes, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateClob, updateClob, updateClob, updateClob, updateDate, updateDate, updateDate, updateDate, updateDateTime, updateDateTime, updateDateTime, updateDateTime, updateDateTime, updateDateTime, updateDateTimeOffset, updateDateTimeOffset, updateDateTimeOffset, updateDateTimeOffset, updateDateTimeOffset, updateDateTimeOffset, updateDouble, updateDouble, updateDouble, updateDouble, updateFloat, updateFloat, updateFloat, updateFloat, updateInt, updateInt, updateInt, updateInt, updateLong, updateLong, updateLong, updateLong, updateMoney, updateMoney, updateMoney, updateMoney, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNString, updateNString, updateNString, updateNString, updateNull, updateNull, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateRef, updateRef, updateRow, updateRowId, updateRowId, updateShort, updateShort, updateShort, updateShort, updateSmallDateTime, updateSmallDateTime, updateSmallDateTime, updateSmallDateTime, updateSmallDateTime, updateSmallDateTime, updateSmallMoney, updateSmallMoney, updateSmallMoney, updateSmallMoney, updateSQLXML, updateSQLXML, updateString, updateString, updateString, updateString, updateTime, updateTime, updateTime, updateTime, updateTime, updateTime, updateTimestamp, updateTimestamp, updateTimestamp, updateTimestamp, updateTimestamp, updateTimestamp, updateUniqueIdentifier, updateUniqueIdentifier, updateUniqueIdentifier, updateUniqueIdentifier, wasNull`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface com.microsoft.sqlserver.jdbc.ISQLServerResultSet

`getDateTimeOffset, getDateTimeOffset, updateDateTimeOffset, updateDateTimeOffset`

### Methods inherited from interface java.sql.ResultSet

`absolute, afterLast, beforeFirst, cancelRowUpdates, clearWarnings, close, deleteRow, findColumn, first, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getBoolean, getByte, getByte, getBytes, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDate, getDouble, getDouble, getFetchDirection, getFetchSize, getFloat, getFloat, getHoldability, getInt, getInt, getLong, getLong, getMetaData, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getNString, getObject, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRow, getRowId, getRowId, getShort, getShort, getSQLXML, getSQLXML, getStatement, getString, getString, getTime, getTime, getTime, getTime, getTimestamp, getTimestamp, getTimestamp, getTimestamp, getType, getUnicodeStream, getUnicodeStream, getURL, getURL, getWarnings, insertRow, isAfterLast, isBeforeFirst, isClosed, isFirst, isLast, last, moveToCurrentRow, moveToInsertRow, next, previous, refreshRow, relative, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, updateArray, updateArray, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateBigDecimal, updateBigDecimal, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBoolean, updateBoolean, updateByte, updateByte, updateBytes, updateBytes, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateClob, updateClob, updateClob, updateClob, updateDate, updateDate, updateDouble, updateDouble, updateFloat, updateFloat, updateInt, updateInt, updateLong, updateLong, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNString, updateNString, updateNull, updateNull, updateObject, updateObject, updateObject, updateObject, updateRef, updateRef, updateRow, updateRowId, updateRowId, updateShort, updateShort, updateSQLXML, updateSQLXML, updateString, updateString, updateTime, updateTime, updateTimestamp, updateTimestamp, wasNull`

### Methods inherited from interface java.sql.Wrapper

`isWrapperFor, unwrap`

### Constructor Detail

#### SQLServerResultSet42

    public SQLServerResultSet42(SQLServerStatement stmtIn)
                         throws SQLServerException

Makes a new result set

Parameters:
  `stmtIn` - the generating statement
Throws:
  `SQLServerException` - when an error occurs

### Method Detail

#### updateObject

    public void updateObject(int index,
                             Object obj,
                             SQLType targetSqlType)
                      throws SQLServerException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Specified by:
  `updateObject` in interface `ResultSet`
Throws:
  `SQLServerException`

#### updateObject

    public void updateObject(int index,
                             Object obj,
                             SQLType targetSqlType,
                             int scale)
                      throws SQLServerException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Specified by:
  `updateObject` in interface `ResultSet`
Throws:
  `SQLServerException`

#### updateObject

    public void updateObject(int index,
                             Object obj,
                             SQLType targetSqlType,
                             int scale,
                             boolean forceEncrypt)
                      throws SQLServerException

Description copied from interface: `ISQLServerResultSet42`
Updates the designated column with an Object value. The updater methods are used to update column values in the current row or the insert row. The updater methods do not update the underlying database; instead the updateRow or insertRow methods are called to update the database. If the second argument is an InputStream then the stream must contain the number of bytes specified by scaleOrLength. If the second argument is a Reader then the reader must contain the number of characters specified by scaleOrLength. If these conditions are not true the driver will generate a SQLException when the statement is executed. The default implementation will throw SQLFeatureNotSupportedException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Parameters:
  `index` - the first column is 1, the second is 2, ...
  `obj` - the new column value
  `targetSqlType` - the SQL type to be sent to the database
  `scale` - for an object of java.math.BigDecimal , this is the number of digits after the decimal point. For Java Object types InputStream and Reader, this is the length of the data in the stream or reader. For all other types, this value will be ignored.
  `forceEncrypt` - If the boolean forceEncrypt is set to true, the query parameter will only be set if the designation column is encrypted and Always Encrypted is enabled on the connection or on the statement.If the boolean forceEncrypt is set to false, the driver will not force encryption on parameters.
Throws:
  `SQLServerException` - If any errors occur.

#### updateObject

    public void updateObject(String columnName,
                             Object obj,
                             SQLType targetSqlType,
                             int scale)
                      throws SQLServerException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Specified by:
  `updateObject` in interface `ResultSet`
Throws:
  `SQLServerException`

#### updateObject

    public void updateObject(String columnName,
                             Object obj,
                             SQLType targetSqlType,
                             int scale,
                             boolean forceEncrypt)
                      throws SQLServerException

Description copied from interface: `ISQLServerResultSet42`
Updates the designated column with an Object value. The updater methods are used to update column values in the current row or the insert row. The updater methods do not update the underlying database; instead the updateRow or insertRow methods are called to update the database. If the second argument is an InputStream then the stream must contain the number of bytes specified by scaleOrLength. If the second argument is a Reader then the reader must contain the number of characters specified by scaleOrLength. If these conditions are not true the driver will generate a SQLException when the statement is executed. The default implementation will throw SQLFeatureNotSupportedException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Parameters:
  `columnName` - the label for the column specified with the SQL AS clause. If the SQL AS clause was not specified, then the label is the name of the column
  `obj` - the new column value
  `targetSqlType` - the SQL type to be sent to the database
  `scale` - for an object of java.math.BigDecimal , this is the number of digits after the decimal point. For Java Object types InputStream and Reader, this is the length of the data in the stream or reader. For all other types, this value will be ignored.
  `forceEncrypt` - If the boolean forceEncrypt is set to true, the query parameter will only be set if the designation column is encrypted and Always Encrypted is enabled on the connection or on the statement.If the boolean forceEncrypt is set to false, the driver will not force encryption on parameters.
Throws:
  `SQLServerException` - If any errors occur.

#### updateObject

    public void updateObject(String columnName,
                             Object obj,
                             SQLType targetSqlType)
                      throws SQLServerException

Specified by:
  `updateObject` in interface `ISQLServerResultSet42`
Specified by:
  `updateObject` in interface `ResultSet`
Throws:
  `SQLServerException`