// Statement.isWrapperFor and Statement.unwrap methods
// to access the driver specific response buffering methods.
if (stmt.isWrapperFor(com.microsoft.sqlserver.jdbc.SQLServerStatement.class))
{
SQLServerStatement SQLstmt =
stmt.unwrap(com.microsoft.sqlserver.jdbc.SQLServerStatement.class);
SQLstmt.setResponseBuffering("adaptive");
System.out.println("Response buffering mode has been set to " +
SQLstmt.getResponseBuffering());
}
// Select all of the document summaries.
rs = stmt.executeQuery("SELECT Title, DocumentSummary FROM Production.Document");