public abstract class PreparedStatement extends Statement implements PreparedStatement, PreparedStatementCallbackInterface
| Modifier and Type | Field and Description |
|---|---|
protected int[] |
clientParamTypeAtFirstExecute |
boolean |
internalPreparedStatement |
MaterialPreparedStatement |
materialPreparedStatement_ |
boolean |
outputRegistered_ |
ColumnMetaData |
parameterMetaData_ |
Object[] |
parameters_ |
protected ClientPooledConnection |
pooledConnection_ |
protected boolean |
singleHopInfoAlreadyFetched_ |
String |
sql_ |
protected boolean |
superFlowExecuteCalled_ |
autoGeneratedKeys_, cachedCursor_, cachedSingletonRowData_, CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, cursorAttributesToSendOnPrepare_, doWriteTimeout, fetchDirection_, fetchSize_, generatedKeysColumnIndexes_, generatedKeysColumnNames_, generatedKeysResultSet_, indexOfCurrentResultSet_, isCommitSql__, isPoolable, isPreparedStatement_, isQuery__, isRollbackSql__, KEEP_CURRENT_RESULT, materialStatement_, numInvisibleRS_, preparedStatementForAutoGeneratedKeys_, resultSetConcurrency_, resultSetHoldability_, resultSetType_, section_, SET_SCHEMA_STATEMENT, singletonRowData_, specialRegisterArrayList, sqlMode_, statementUUID, TIMEOUT_STATEMENTCLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO| Constructor and Description |
|---|
PreparedStatement(Agent agent,
Connection connection,
String sql,
int type,
int concurrency,
int holdability,
int autoGeneratedKeys,
String[] columnNames,
int[] columnIndexes,
ClientPooledConnection cpc)
The PreparedStatementConstructor used for jdbc 2 prepared statements
with scroll attributes.
|
PreparedStatement(Agent agent,
Connection connection,
String sql,
Section section,
ClientPooledConnection cpc)
The PreparedStatement constructor used for JDBC 2 positioned update
statements.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addBatch() |
void |
clearParameters() |
void |
completeDescribeInput(ColumnMetaData parameterMetaData,
Sqlca sqlca) |
void |
completeDescribeOutput(ColumnMetaData resultSetMetaData,
Sqlca sqlca) |
void |
completeLocalCommit(Iterator listenerIterator) |
void |
completeLocalRollback(Iterator listenerIterator) |
boolean |
execute() |
boolean |
execute(String sql) |
boolean |
execute(String sql,
int autoGeneratedKeys) |
boolean |
execute(String sql,
int[] columnIndexes) |
boolean |
execute(String sql,
String[] columnNames) |
int[] |
executeBatch() |
int[] |
executeBatchX(boolean supportsQueryBatchRequest,
int currExecSeq) |
ResultSet |
executeQuery() |
ResultSet |
executeQuery(String sql) |
int |
executeUpdate() |
int |
executeUpdate(String sql) |
int |
executeUpdate(String sql,
int autoGeneratedKeys) |
int |
executeUpdate(String sql,
int[] columnIndexes) |
int |
executeUpdate(String sql,
String[] columnNames) |
protected void |
flowExecute(int executeType,
int currExecSeq) |
protected void |
flowExecuteRead(int executeType,
com.pivotal.gemfirexd.internal.client.am.PreparedStatement.FlowExecuteContext ctx) |
protected com.pivotal.gemfirexd.internal.client.am.PreparedStatement.FlowExecuteContext |
flowExecuteWrite(int executeType,
int currExecSeq) |
protected String |
getClientParamType(int[] paramType) |
protected String |
getJdbcStatementInterfaceName()
Returns the name of the java.sql interface implemented by this class.
|
ResultSetMetaData |
getMetaData() |
ParameterMetaData |
getParameterMetaData() |
NetResultSet |
getSuperResultSet() |
protected void |
initResetPreparedStatement() |
void |
listenToUnitOfWork() |
protected static int[] |
makeNewClientParamTypeFrom(int[] sourceClientParamType) |
protected void |
markClosed(boolean removeListener)
This method cleans up client-side resources held by this Statement.
|
void |
readDescribeInput() |
void |
readDescribeOutput() |
void |
readExecute() |
void |
reset(boolean fullReset) |
void |
resetPreparedStatement(Agent agent,
Connection connection,
String sql,
int type,
int concurrency,
int holdability,
int autoGeneratedKeys,
String[] columnNames,
int[] columnIndexes) |
void |
resetPreparedStatement(Agent agent,
Connection connection,
String sql,
Section section) |
void |
resetPreparedStatement(Agent agent,
Connection connection,
String sql,
Section section,
ColumnMetaData parameterMetaData,
ColumnMetaData resultSetMetaData) |
protected int[] |
setAndStoreClientParamType(int[] clientParamtype) |
void |
setArray(int parameterIndex,
Array x) |
void |
setAsciiStream(int parameterIndex,
InputStream x)
Sets the designated parameter to the given input stream.
|
void |
setAsciiStream(int parameterIndex,
InputStream x,
int length)
We do this inefficiently and read it all in here.
|
void |
setAsciiStream(int parameterIndex,
InputStream x,
long length)
We do this inefficiently and read it all in here.
|
void |
setBigDecimal(int parameterIndex,
BigDecimal x) |
void |
setBinaryStream(int parameterIndex,
InputStream x)
Sets the designated parameter to the given input stream.
|
void |
setBinaryStream(int parameterIndex,
InputStream x,
int length)
sets the parameter to the Binary Stream object
|
void |
setBinaryStream(int parameterIndex,
InputStream x,
long length)
sets the parameter to the Binary Stream object
|
protected void |
setBinaryStreamX(int parameterIndex,
InputStream x,
int length) |
void |
setBlob(int parameterIndex,
Blob x) |
void |
setBlob(int parameterIndex,
InputStream inputStream)
Sets the designated parameter to a
InputStream object. |
void |
setBlob(int parameterIndex,
InputStream inputStream,
long length)
Sets the designated parameter to a InputStream object.
|
void |
setBlobX(int parameterIndex,
Blob x) |
void |
setBoolean(int parameterIndex,
boolean x) |
void |
setByte(int parameterIndex,
byte x) |
void |
setBytes(int parameterIndex,
byte[] x) |
void |
setBytesX(int parameterIndex,
byte[] x) |
void |
setCharacterStream(int parameterIndex,
Reader x)
Sets the designated parameter to the given
Reader object. |
void |
setCharacterStream(int parameterIndex,
Reader x,
int length)
Sets the designated parameter to the given Reader, which will have
the specified number of bytes.
|
void |
setCharacterStream(int parameterIndex,
Reader x,
long length)
Sets the designated parameter to the given Reader, which will have
the specified number of bytes.
|
void |
setClob(int parameterIndex,
Clob x) |
void |
setClob(int parameterIndex,
Reader reader)
Sets the designated parameter to a
Reader object. |
void |
setClob(int parameterIndex,
Reader reader,
long length)
Sets the designated parameter to a Reader object.
|
void |
setDate(int parameterIndex,
Date x) |
void |
setDate(int parameterIndex,
Date x,
Calendar calendar) |
void |
setDouble(int parameterIndex,
double x) |
void |
setFloat(int parameterIndex,
float x) |
void |
setInt(int parameterIndex,
int x) |
void |
setLong(int parameterIndex,
long x) |
void |
setNull(int parameterIndex,
int jdbcType) |
void |
setNull(int parameterIndex,
int jdbcType,
String typeName) |
void |
setObject(int parameterIndex,
Object x) |
void |
setObject(int parameterIndex,
Object x,
int targetJdbcType) |
void |
setObject(int parameterIndex,
Object x,
int targetJdbcType,
int scale) |
void |
setRef(int parameterIndex,
Ref x) |
void |
setShort(int parameterIndex,
short x) |
void |
setString(int parameterIndex,
String x) |
void |
setTime(int parameterIndex,
Time x) |
void |
setTime(int parameterIndex,
Time x,
Calendar calendar) |
void |
setTimestamp(int parameterIndex,
Timestamp x) |
void |
setTimestamp(int parameterIndex,
Timestamp x,
Calendar calendar) |
void |
setUnicodeStream(int parameterIndex,
InputStream x,
int length)
Deprecated.
|
void |
setURL(int parameterIndex,
URL x) |
protected ResultSet |
singleHopPrepStmntExecuteQuery() |
void |
writeDescribeInput(Section section) |
void |
writeDescribeOutput(Section section) |
void |
writeExecute(Section section,
ColumnMetaData parameterMetaData,
Object[] inputs,
int numInputColumns,
boolean outputExpected,
boolean chainedWritesFollowingSetLob) |
accumulateWarning, addBatch, cancel, checkForDuplicateCursorName, checkForStoredProcResultSetCount, cleanSingleHopPrepStmnt, clearBatch, clearWarnings, close, closeX, completeExecute, completeExecuteCall, completeExecuteCall, completeExecuteCallOpenQuery, completeExecuteImmediate, completeExecuteSetStatement, completeOpenQuery, completePrepare, completePrepareDescribeOutput, completeSqlca, completeStatementIDRead, finalize, getConnection, getConnectionCallbackInterface, getFetchDirection, getFetchSize, getGeneratedKeys, getGuessedResultSetMetaData, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getSection, getSqlWarnings, getUpdateCount, getWarnings, initResetPreparedStatement, isCallMode, isClosed, isClosedNoThrow, isPoolable, isQueryMode, isWrapperFor, jdbc3FeatureNotSupported, jdbc3FeatureNotSupported, markAutoCommitted, needStatementUUID, readExecuteCall, readExecuteImmediate, readExecuteImmediateForBatch, readOpenQuery, readPrepare, readPrepareDescribeOutput, readSetSpecialRegister, readStatementID, removeClientCursorNameFromCache, resetStatement, resetStatement, resultSetCommitting, resultSetCommitting, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setMaxFieldSize, setMaxRows, setOwner, setPoolable, setQueryTimeout, setupCursorNameCacheAndMappings, setUpdateCount, substituteClientCursorNameWithServerCursorName, upperCaseProcedureName, writeExecuteCall, writeExecuteImmediate, writeGetStmtUUID, writeOpenQuery, writePrepare, writePrepareDescribeOutput, writeSetSpecialRegisterclone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsetNCharacterStream, setNCharacterStream, setNClob, setNClob, setNClob, setNString, setRowId, setSQLXMLaddBatch, cancel, clearBatch, clearWarnings, close, closeOnCompletion, getConnection, getFetchDirection, getFetchSize, getGeneratedKeys, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, isCloseOnCompletion, isPoolable, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeoutisWrapperFor, unwrapaccumulateWarning, completeExecute, completeExecuteCall, completeExecuteCall, completeExecuteCallOpenQuery, completeExecuteImmediate, completeExecuteSetStatement, completeOpenQuery, completePrepare, completePrepareDescribeOutput, completeSqlca, completeStatementIDRead, getConnectionCallbackInterface, getGuessedResultSetMetaData, getSectionpublic MaterialPreparedStatement materialPreparedStatement_
public String sql_
public boolean outputRegistered_
public Object[] parameters_
public ColumnMetaData parameterMetaData_
protected final ClientPooledConnection pooledConnection_
protected boolean superFlowExecuteCalled_
protected boolean singleHopInfoAlreadyFetched_
protected int[] clientParamTypeAtFirstExecute
public volatile boolean internalPreparedStatement
public PreparedStatement(Agent agent, Connection connection, String sql, Section section, ClientPooledConnection cpc) throws SqlException
agent - The instance of NetAgent associated with this
CallableStatement object.connection - The connection object associated with this
PreparedStatement Object.sql - A String object that is the SQL statement to be sent
to the database.section - Sectioncpc - The ClientPooledConnection wraps the underlying physical
connection associated with this prepared statement.
It is used to pass the Statement closed and the Statement
error occurred events that occur back to the
ClientPooledConnection.SqlExceptionpublic PreparedStatement(Agent agent, Connection connection, String sql, int type, int concurrency, int holdability, int autoGeneratedKeys, String[] columnNames, int[] columnIndexes, ClientPooledConnection cpc) throws SqlException
agent - The instance of NetAgent associated with this
CallableStatement object.connection - The connection object associated with this
PreparedStatement Object.sql - A String object that is the SQL statement
to be sent to the database.type - One of the ResultSet type constants.concurrency - One of the ResultSet concurrency constants.holdability - One of the ResultSet holdability constants.autoGeneratedKeys - a flag indicating whether auto-generated
keys should be returned.columnNames - an array of column names indicating the columns that
should be returned from the inserted row or rows.columnIndexes - an array of column names indicating the columns that
should be returned from the inserted row.cpc - The ClientPooledConnection wraps the underlying physical
connection associated with this prepared statement
it is used to pass the Statement closed and the Statement
error occurred events that occur back to the
ClientPooledConnection.SqlExceptionprotected void initResetPreparedStatement()
public void reset(boolean fullReset)
throws SqlException
reset in class StatementSqlExceptionpublic NetResultSet getSuperResultSet() throws SQLException
SQLExceptionprotected int[] setAndStoreClientParamType(int[] clientParamtype)
setAndStoreClientParamType in class Statementprotected static int[] makeNewClientParamTypeFrom(int[] sourceClientParamType)
protected String getClientParamType(int[] paramType)
public void resetPreparedStatement(Agent agent, Connection connection, String sql, Section section) throws SqlException
SqlExceptionpublic void resetPreparedStatement(Agent agent, Connection connection, String sql, int type, int concurrency, int holdability, int autoGeneratedKeys, String[] columnNames, int[] columnIndexes) throws SqlException
SqlExceptionpublic void resetPreparedStatement(Agent agent, Connection connection, String sql, Section section, ColumnMetaData parameterMetaData, ColumnMetaData resultSetMetaData) throws SqlException
SqlExceptionpublic boolean execute(String sql) throws SQLException
execute in interface Statementexecute in class StatementSQLExceptionpublic ResultSet executeQuery(String sql) throws SQLException
executeQuery in interface StatementexecuteQuery in class StatementSQLExceptionpublic int executeUpdate(String sql) throws SQLException
executeUpdate in interface StatementexecuteUpdate in class StatementSQLExceptionpublic ResultSet executeQuery() throws SQLException
executeQuery in interface PreparedStatementSQLExceptionprotected ResultSet singleHopPrepStmntExecuteQuery() throws SQLException
SQLExceptionpublic int executeUpdate()
throws SQLException
executeUpdate in interface PreparedStatementSQLExceptionpublic void setNull(int parameterIndex,
int jdbcType)
throws SQLException
setNull in interface PreparedStatementSQLExceptionpublic void setNull(int parameterIndex,
int jdbcType,
String typeName)
throws SQLException
setNull in interface PreparedStatementSQLExceptionpublic void setBoolean(int parameterIndex,
boolean x)
throws SQLException
setBoolean in interface PreparedStatementSQLExceptionpublic void setByte(int parameterIndex,
byte x)
throws SQLException
setByte in interface PreparedStatementSQLExceptionpublic void setShort(int parameterIndex,
short x)
throws SQLException
setShort in interface PreparedStatementSQLExceptionpublic void setInt(int parameterIndex,
int x)
throws SQLException
setInt in interface PreparedStatementSQLExceptionpublic void setLong(int parameterIndex,
long x)
throws SQLException
setLong in interface PreparedStatementSQLExceptionpublic void setFloat(int parameterIndex,
float x)
throws SQLException
setFloat in interface PreparedStatementSQLExceptionpublic void setDouble(int parameterIndex,
double x)
throws SQLException
setDouble in interface PreparedStatementSQLExceptionpublic void setBigDecimal(int parameterIndex,
BigDecimal x)
throws SQLException
setBigDecimal in interface PreparedStatementSQLExceptionpublic void setDate(int parameterIndex,
Date x)
throws SQLException
setDate in interface PreparedStatementSQLExceptionpublic void setDate(int parameterIndex,
Date x,
Calendar calendar)
throws SQLException
setDate in interface PreparedStatementSQLExceptionpublic void setTime(int parameterIndex,
Time x)
throws SQLException
setTime in interface PreparedStatementSQLExceptionpublic void setTime(int parameterIndex,
Time x,
Calendar calendar)
throws SQLException
setTime in interface PreparedStatementSQLExceptionpublic void setTimestamp(int parameterIndex,
Timestamp x)
throws SQLException
setTimestamp in interface PreparedStatementSQLExceptionpublic void setTimestamp(int parameterIndex,
Timestamp x,
Calendar calendar)
throws SQLException
setTimestamp in interface PreparedStatementSQLExceptionpublic void setString(int parameterIndex,
String x)
throws SQLException
setString in interface PreparedStatementSQLExceptionpublic void setBytes(int parameterIndex,
byte[] x)
throws SQLException
setBytes in interface PreparedStatementSQLExceptionpublic void setBytesX(int parameterIndex,
byte[] x)
throws SqlException
SqlExceptionpublic void setBinaryStream(int parameterIndex,
InputStream x,
long length)
throws SQLException
setBinaryStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the binary parameter valuelength - the number of bytes in the streamSQLException - thrown on failure.public void setBinaryStream(int parameterIndex,
InputStream x,
int length)
throws SQLException
setBinaryStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the binary parameter valuelength - the number of bytes in the streamSQLException - thrown on failure.protected void setBinaryStreamX(int parameterIndex,
InputStream x,
int length)
throws SqlException
SqlExceptionpublic void setAsciiStream(int parameterIndex,
InputStream x,
long length)
throws SQLException
setAsciiStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the ASCII parameter valuelength - the number of bytes in the streamSQLException - thrown on failure.public void setAsciiStream(int parameterIndex,
InputStream x,
int length)
throws SQLException
setAsciiStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the ASCII parameter valuelength - the number of bytes in the streamSQLException - thrown on failure.public void setUnicodeStream(int parameterIndex,
InputStream x,
int length)
throws SQLException
setUnicodeStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the UNICODE parameter
valuelength - the number of bytes in the streamSQLException - throws feature not implemented.public void setCharacterStream(int parameterIndex,
Reader x)
throws SQLException
Reader object.
When a very large UNICODE value is input to a LONGVARCHAR parameter, it
may be more practical to send it via a java.io.Reader
object. The data will be read from the stream as needed until
end-of-file is reached. The JDBC driver will do any necessary conversion
from UNICODE to the database char format.setCharacterStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java.io.Reader object that contains the
Unicode dataSQLException - if a database access error occurs or this method is
called on a closed PreparedStatementpublic void setCharacterStream(int parameterIndex,
Reader x,
long length)
throws SQLException
setCharacterStream in interface PreparedStatementparameterIndex - the index of the parameter to which this set
method is appliedx - the java Reader which contains the UNICODE valuelength - the number of bytes in the streamSQLException - thrown on failure.public void setCharacterStream(int parameterIndex,
Reader x,
int length)
throws SQLException
setCharacterStream in interface PreparedStatementparameterIndex - the index of the parameter to which this
set method is appliedx - the java Reader which contains the UNICODE valuelength - the number of bytes in the streamSQLException - thrown on failure.public void setBlob(int parameterIndex,
Blob x)
throws SQLException
setBlob in interface PreparedStatementSQLExceptionpublic void setBlobX(int parameterIndex,
Blob x)
throws SqlException
SqlExceptionpublic void setClob(int parameterIndex,
Clob x)
throws SQLException
setClob in interface PreparedStatementSQLExceptionpublic void setArray(int parameterIndex,
Array x)
throws SQLException
setArray in interface PreparedStatementSQLExceptionpublic void setRef(int parameterIndex,
Ref x)
throws SQLException
setRef in interface PreparedStatementSQLExceptionpublic void setObject(int parameterIndex,
Object x)
throws SQLException
setObject in interface PreparedStatementSQLExceptionpublic void setObject(int parameterIndex,
Object x,
int targetJdbcType)
throws SQLException
setObject in interface PreparedStatementSQLExceptionpublic void setObject(int parameterIndex,
Object x,
int targetJdbcType,
int scale)
throws SQLException
setObject in interface PreparedStatementSQLExceptionpublic void clearParameters()
throws SQLException
clearParameters in interface PreparedStatementSQLExceptionpublic boolean execute()
throws SQLException
execute in interface PreparedStatementSQLExceptionpublic void addBatch()
throws SQLException
addBatch in interface PreparedStatementSQLExceptionpublic int[] executeBatch()
throws SQLException,
BatchUpdateException
executeBatch in interface StatementexecuteBatch in class StatementSQLExceptionBatchUpdateExceptionpublic ResultSetMetaData getMetaData() throws SQLException
getMetaData in interface PreparedStatementSQLExceptionpublic boolean execute(String sql, int autoGeneratedKeys) throws SQLException
execute in interface Statementexecute in class StatementSQLExceptionpublic boolean execute(String sql, String[] columnNames) throws SQLException
execute in interface Statementexecute in class StatementSQLExceptionpublic boolean execute(String sql, int[] columnIndexes) throws SQLException
execute in interface Statementexecute in class StatementSQLExceptionpublic int executeUpdate(String sql, int autoGeneratedKeys) throws SQLException
executeUpdate in interface StatementexecuteUpdate in class StatementSQLExceptionpublic int executeUpdate(String sql, String[] columnNames) throws SQLException
executeUpdate in interface StatementexecuteUpdate in class StatementSQLExceptionpublic int executeUpdate(String sql, int[] columnIndexes) throws SQLException
executeUpdate in interface StatementexecuteUpdate in class StatementSQLExceptionpublic void setURL(int parameterIndex,
URL x)
throws SQLException
setURL in interface PreparedStatementSQLExceptionpublic ParameterMetaData getParameterMetaData() throws SQLException
getParameterMetaData in interface PreparedStatementSQLExceptionpublic void writeExecute(Section section, ColumnMetaData parameterMetaData, Object[] inputs, int numInputColumns, boolean outputExpected, boolean chainedWritesFollowingSetLob) throws SqlException
SqlExceptionpublic void readExecute()
throws SqlException
SqlExceptionpublic void writeDescribeInput(Section section) throws SqlException
SqlExceptionpublic void readDescribeInput()
throws SqlException
SqlExceptionpublic void completeDescribeInput(ColumnMetaData parameterMetaData, Sqlca sqlca)
completeDescribeInput in interface PreparedStatementCallbackInterfacepublic void writeDescribeOutput(Section section) throws SqlException
SqlExceptionpublic void readDescribeOutput()
throws SqlException
SqlExceptionpublic void completeDescribeOutput(ColumnMetaData resultSetMetaData, Sqlca sqlca)
completeDescribeOutput in interface PreparedStatementCallbackInterfaceprotected com.pivotal.gemfirexd.internal.client.am.PreparedStatement.FlowExecuteContext flowExecuteWrite(int executeType,
int currExecSeq)
throws SqlException
SqlExceptionprotected final void flowExecuteRead(int executeType,
com.pivotal.gemfirexd.internal.client.am.PreparedStatement.FlowExecuteContext ctx)
throws SqlException
SqlExceptionprotected void flowExecute(int executeType,
int currExecSeq)
throws SqlException
SqlExceptionpublic int[] executeBatchX(boolean supportsQueryBatchRequest,
int currExecSeq)
throws SqlException,
SQLException,
BatchUpdateException
public void listenToUnitOfWork()
listenToUnitOfWork in interface UnitOfWorkListenerlistenToUnitOfWork in class Statementpublic void completeLocalCommit(Iterator listenerIterator)
completeLocalCommit in interface UnitOfWorkListenercompleteLocalCommit in class Statementpublic void completeLocalRollback(Iterator listenerIterator)
completeLocalRollback in interface UnitOfWorkListenercompleteLocalRollback in class Statementprotected String getJdbcStatementInterfaceName()
getJdbcStatementInterfaceName in class Statementprotected void markClosed(boolean removeListener)
StatementremoveListener - if true the Statement will be removed
from the open statements list and PreparedStatement will also be removed
from commit and rollback listeners list in
com.pivotal.gemfirexd.internal.client.am.Connection.public void setAsciiStream(int parameterIndex,
InputStream x)
throws SQLException
LONGVARCHAR
parameter, it may be more practical to send it via a
java.io.InputStream. Data will be read from the stream as
needed until end-of-file is reached. The JDBC driver will do any
necessary conversion from ASCII to the database char format.setAsciiStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the Java input stream that contains the ASCII parameter valueSQLException - if a database access error occurs or this method is
called on a closed PreparedStatementpublic void setBinaryStream(int parameterIndex,
InputStream x)
throws SQLException
LONGVARBINARY
parameter, it may be more practical to send it via a
java.io.InputStream object. The data will be read from the
stream as needed until end-of-file is reached.setBinaryStream in interface PreparedStatementparameterIndex - the first parameter is 1, the second is 2, ...x - the java input stream which contains the binary parameter valueSQLException - if a database access error occurs or this method is
called on a closed PreparedStatementpublic void setClob(int parameterIndex,
Reader reader)
throws SQLException
Reader object.setClob in interface PreparedStatementparameterIndex - index of the first parameter is 1, the second is
2, ...reader - an object that contains the data to set the parameter
value to.SQLException - if parameterIndex does not correspond to a
parameter marker in the SQL statement; if a database access error
occurs; this method is called on a closed PreparedStatementor if
parameterIndex does not correspond to a parameter marker in the SQL
statementpublic void setClob(int parameterIndex,
Reader reader,
long length)
throws SQLException
setClob in interface PreparedStatementparameterIndex - index of the first parameter is 1, the second is 2, ...reader - An object that contains the data to set the parameter value to.length - the number of characters in the parameter data.SQLException - if parameterIndex does not correspond to a parameter
marker in the SQL statement, or if the length specified is less than zero.public void setBlob(int parameterIndex,
InputStream inputStream)
throws SQLException
InputStream object.
This method differs from the setBinaryStream(int, InputStream)
method because it informs the driver that the parameter value
should be sent to the server as a BLOB. When the
setBinaryStream method is used, the driver may have to do
extra work to determine whether the parameter data should be sent to the
server as a LONGVARBINARY or a BLOBsetBlob in interface PreparedStatementparameterIndex - index of the first parameter is 1, the second is
2, ...inputStream - an object that contains the data to set the parameter
value to.SQLException - if a database access error occurs, this method is
called on a closed PreparedStatement or if
parameterIndex does not correspond to a parameter
marker in the SQL statementpublic void setBlob(int parameterIndex,
InputStream inputStream,
long length)
throws SQLException
setBlob in interface PreparedStatementparameterIndex - index of the first parameter is 1,
the second is 2, ...inputStream - An object that contains the data to set the parameter
value to.length - the number of bytes in the parameter data.SQLException - if parameterIndex does not correspond
to a parameter marker in the SQL statement, if the length specified
is less than zero or if the number of bytes in the inputstream does not match
the specfied length.Copyright © 2010-2015 Pivotal Software, Inc. All rights reserved.