类 ClientPreparedStatement
- java.lang.Object
-
- com.mysql.cj.jdbc.StatementImpl
-
- com.mysql.cj.jdbc.ClientPreparedStatement
-
- 所有已实现的接口:
JdbcPreparedStatement,JdbcStatement,Query,AutoCloseable,PreparedStatement,Statement,Wrapper
- 直接已知子类:
CallableStatement,ServerPreparedStatement
public class ClientPreparedStatement extends StatementImpl implements JdbcPreparedStatement
A SQL Statement is pre-compiled and stored in a PreparedStatement object. This object can then be used to efficiently execute this statement multiple times.Note: The setXXX methods for setting IN parameter values must specify types that are compatible with the defined SQL type of the input parameter. For instance, if the IN parameter has SQL type Integer, then setInt should be used.
If arbitrary parameter type conversions are required, then the setObject method should be used with a target SQL type.
-
-
嵌套类概要
-
从接口继承的嵌套类/接口 com.mysql.cj.Query
Query.CancelStatus
-
-
字段概要
字段 修饰符和类型 字段 说明 protected StringbatchedValuesClauseprotected booleanbatchHasPlainStatementsDoes the batch (if any) contain "plain" statements added by Statement.addBatch(String)?protected MysqlParameterMetadataparameterMetaDataprotected intrewrittenBatchSize-
从类继承的字段 com.mysql.cj.jdbc.StatementImpl
batchedGeneratedKeys, charEncoding, commandBuilder, connection, continueBatchOnError, doEscapeProcessing, dontCheckOnDuplicateKeyUpdateInSQL, dontTrackOpenResources, dumpQueriesOnException, exceptionInterceptor, generatedKeysResults, holdResultsOpenOverClose, isClosed, lastInsertId, lastQueryIsOnDupKeyUpdate, logSlowQueries, maxAllowedPacket, maxFieldSize, maxRows, openResults, pedantic, PING_MARKER, pingTarget, profileSQL, query, results, resultSetConcurrency, resultSetFactory, retrieveGeneratedKeys, rewriteBatchedStatements, session, updateCount, USES_VARIABLES_FALSE, USES_VARIABLES_TRUE, USES_VARIABLES_UNKNOWN, useUsageAdvisor, warningChain
-
从接口继承的字段 com.mysql.cj.jdbc.JdbcStatement
MAX_ROWS
-
-
构造器概要
构造器 限定符 构造器 说明 protectedClientPreparedStatement(JdbcConnection conn, String db)Constructor used by server-side prepared statementsClientPreparedStatement(JdbcConnection conn, String sql, String db)Constructor for the PreparedStatement class.ClientPreparedStatement(JdbcConnection conn, String sql, String db, QueryInfo cachedQueryInfo)Creates a new PreparedStatement object.
-
方法概要
所有方法 静态方法 实例方法 具体方法 已过时的方法 修饰符和类型 方法 说明 voidaddBatch()voidaddBatch(String sql)protected voidcheckBounds(int paramIndex, int parameterIndexOffset)protected booleancheckReadOnlySafeStatement()Check to see if the statement is safe for read-only replicas after failover.voidclearBatch()voidclearParameters()protected booleancontainsOnDuplicateKeyUpdate()booleanexecute()protected long[]executeBatchedInserts(int batchTimeout)Rewrites the already prepared statement into a multi-value insert statement and executes the entire batch using this new statement.protected long[]executeBatchInternal()protected long[]executeBatchSerially(int batchTimeout)Executes the current batch of statements by executing them one-by-one.protected <M extends Message>
ResultSetInternalMethodsexecuteInternal(int maxRowsToRetrieve, M sendPacket, boolean createStreamingResultSet, boolean queryIsSelectOnly, ColumnDefinition metadata, boolean isBatch)Actually execute the prepared statement.longexecuteLargeUpdate()protected long[]executePreparedBatchAsMultiStatement(int batchTimeout)Rewrites the already prepared statement into a multi-statement query and executes the entire batch using this new statement.ResultSetexecuteQuery()intexecuteUpdate()protected longexecuteUpdateInternal(boolean clearBatchedGeneratedKeysAndWarnings, boolean isBatch)protected longexecuteUpdateInternal(QueryBindings bindings, boolean isReallyBatch)Added to allow batch-updatesbyte[]getBytesRepresentation(int parameterIndex)intgetCoreParameterIndex(int paramIndex)protected static ClientPreparedStatementgetInstance(JdbcConnection conn, String sql, String db)Creates a prepared statement instanceprotected static ClientPreparedStatementgetInstance(JdbcConnection conn, String sql, String db, QueryInfo cachedQueryInfo)Creates a prepared statement instanceResultSetMetaDatagetMetaData()ParameterBindingsgetParameterBindings()protected intgetParameterIndexOffset()For calling stored functions, this will be -1 as Connector/J does not count the first '?'ParameterMetaDatagetParameterMetaData()StringgetPreparedSql()QueryBindingsgetQueryBindings()QueryInfogetQueryInfo()intgetUpdateCount()protected voidinitQuery()booleanisNull(int paramIndex)protected booleanisResultSetProducingQuery()Checks if the given SQL query is a result set producing query.protected ClientPreparedStatementprepareBatchedInsertSQL(JdbcConnection localConn, int numBatches)Returns a prepared statement for the number of batched parameters, used when re-writing batch INSERTs.voidrealClose(boolean calledExplicitly, boolean closeOpenResults)Closes this statement, and frees resources.voidsetArray(int i, Array x)voidsetAsciiStream(int parameterIndex, InputStream x)voidsetAsciiStream(int parameterIndex, InputStream x, int length)voidsetAsciiStream(int parameterIndex, InputStream x, long length)voidsetBigDecimal(int parameterIndex, BigDecimal x)voidsetBigInteger(int parameterIndex, BigInteger x)voidsetBinaryStream(int parameterIndex, InputStream x)voidsetBinaryStream(int parameterIndex, InputStream x, int length)voidsetBinaryStream(int parameterIndex, InputStream x, long length)voidsetBlob(int parameterIndex, InputStream inputStream)voidsetBlob(int parameterIndex, InputStream inputStream, long length)voidsetBlob(int i, Blob x)voidsetBoolean(int parameterIndex, boolean x)voidsetByte(int parameterIndex, byte x)voidsetBytes(int parameterIndex, byte[] x)voidsetBytes(int parameterIndex, byte[] x, boolean escapeIfNeeded)voidsetCharacterStream(int parameterIndex, Reader reader)voidsetCharacterStream(int parameterIndex, Reader reader, int length)voidsetCharacterStream(int parameterIndex, Reader reader, long length)voidsetClob(int parameterIndex, Reader reader)voidsetClob(int parameterIndex, Reader reader, long length)voidsetClob(int i, Clob x)voidsetDate(int parameterIndex, Date x)voidsetDate(int parameterIndex, Date x, Calendar cal)voidsetDouble(int parameterIndex, double x)voidsetFloat(int parameterIndex, float x)voidsetInt(int parameterIndex, int x)voidsetLong(int parameterIndex, long x)voidsetNCharacterStream(int parameterIndex, Reader value)voidsetNCharacterStream(int parameterIndex, Reader reader, long length)voidsetNClob(int parameterIndex, Reader reader)voidsetNClob(int parameterIndex, Reader reader, long length)voidsetNClob(int parameterIndex, NClob value)voidsetNString(int parameterIndex, String x)Set a parameter to a Java String value.voidsetNull(int parameterIndex, int sqlType)voidsetNull(int parameterIndex, int sqlType, String typeName)voidsetNull(int parameterIndex, MysqlType mysqlType)voidsetObject(int parameterIndex, Object parameterObj)voidsetObject(int parameterIndex, Object parameterObj, int targetSqlType)voidsetObject(int parameterIndex, Object parameterObj, int targetSqlType, int scale)voidsetObject(int parameterIndex, Object parameterObj, SQLType targetSqlType)voidsetObject(int parameterIndex, Object x, SQLType targetSqlType, int scaleOrLength)protected intsetOneBatchedParameterSet(PreparedStatement batchedStatement, int batchedParamIndex, Object paramSet)voidsetRef(int i, Ref x)protected voidsetRetrieveGeneratedKeys(boolean flag)voidsetRowId(int parameterIndex, RowId x)voidsetShort(int parameterIndex, short x)voidsetSQLXML(int parameterIndex, SQLXML xmlObject)voidsetString(int parameterIndex, String x)voidsetTime(int parameterIndex, Time x)voidsetTime(int parameterIndex, Time x, Calendar cal)voidsetTimestamp(int parameterIndex, Timestamp x)voidsetTimestamp(int parameterIndex, Timestamp x, Calendar cal)voidsetUnicodeStream(int parameterIndex, InputStream x, int length)已过时。voidsetURL(int parameterIndex, URL arg)StringtoString()Returns this PreparedStatement represented as a string.-
从类继承的方法 com.mysql.cj.jdbc.StatementImpl
addBatch, cancel, checkCancelTimeout, checkClosed, checkNullOrEmptyQuery, clearAttributes, clearBatchedArgs, clearWarnings, close, closeAllOpenResults, closeOnCompletion, closeQuery, containsOnDuplicateKeyInString, createStreamingResultSet, disableStreamingResults, doPingInstead, enableStreamingResults, execute, execute, execute, execute, executeBatch, executeLargeBatch, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeQuery, executeSimpleNonQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, executeUpdateInternal, generatePingResultSet, getBatchedArgs, getBatchedGeneratedKeys, getBatchedGeneratedKeys, getCancelTimeoutMutex, getConnection, getCurrentDatabase, getExceptionInterceptor, getExecuteTime, getFetchDirection, getFetchSize, getGeneratedKeys, getGeneratedKeysInternal, getGeneratedKeysInternal, getId, getLargeMaxRows, getLargeUpdateCount, getLastInsertID, getLocalInfileInputStream, getLongUpdateCount, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getOpenResultSetCount, getQuery, getQueryAttributesBindings, getQueryTimeout, getResultFetchSize, getResultSet, getResultSetConcurrency, getResultSetFactory, getResultSetHoldability, getResultSetInternal, getResultSetType, getResultType, getServerStatementId, getSession, getStatementExecuting, getTimeoutInMillis, getWarnings, handleExceptionForBatch, hasDeadlockOrTimeoutRolledBackTx, implicitlyCloseAllOpenResults, isClearWarningsCalled, isClosed, isCloseOnCompletion, isNonResultSetProducingQuery, isPoolable, isResultSetProducingQuery, isWrapperFor, processMultiCountsAndKeys, removeOpenResultSet, resetCancelledState, setAttribute, setCancelStatus, setClearWarningsCalled, setCurrentDatabase, setCursorName, setEscapeProcessing, setExecuteTime, setFetchDirection, setFetchSize, setHoldResultsOpenOverClose, setLargeMaxRows, setLocalInfileInputStream, setMaxFieldSize, setMaxRows, setPingTarget, setPoolable, setQueryTimeout, setResultFetchSize, setResultType, setTimeoutInMillis, setupStreamingTimeout, startQueryTimer, statementBegins, stopQueryTimer, unwrap
-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
从接口继承的方法 com.mysql.cj.jdbc.JdbcStatement
clearAttributes, disableStreamingResults, enableStreamingResults, getExceptionInterceptor, getLocalInfileInputStream, getOpenResultSetCount, getQuery, getResultSetInternal, removeOpenResultSet, setAttribute, setHoldResultsOpenOverClose, setLocalInfileInputStream, setPingTarget
-
从接口继承的方法 com.mysql.cj.Query
addBatch, checkCancelTimeout, clearBatchedArgs, closeQuery, getBatchedArgs, getCancelTimeoutMutex, getCurrentDatabase, getExecuteTime, getId, getQueryAttributesBindings, getResultFetchSize, getResultSetFactory, getResultType, getSession, getStatementExecuting, getTimeoutInMillis, isClearWarningsCalled, resetCancelledState, setCancelStatus, setClearWarningsCalled, setCurrentDatabase, setExecuteTime, setResultFetchSize, setResultType, setTimeoutInMillis, startQueryTimer, statementBegins, stopQueryTimer
-
从接口继承的方法 java.sql.Statement
cancel, clearWarnings, close, closeOnCompletion, enquoteIdentifier, enquoteLiteral, enquoteNCharLiteral, execute, execute, execute, execute, executeBatch, executeLargeBatch, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeLargeUpdate, executeQuery, executeUpdate, executeUpdate, executeUpdate, executeUpdate, getConnection, getFetchDirection, getFetchSize, getGeneratedKeys, getLargeMaxRows, getLargeUpdateCount, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getWarnings, isClosed, isCloseOnCompletion, isPoolable, isSimpleIdentifier, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setLargeMaxRows, setMaxFieldSize, setMaxRows, setPoolable, setQueryTimeout
-
从接口继承的方法 java.sql.Wrapper
isWrapperFor, unwrap
-
-
-
-
字段详细资料
-
batchHasPlainStatements
protected boolean batchHasPlainStatements
Does the batch (if any) contain "plain" statements added by Statement.addBatch(String)? If so, we can't re-write it to use multi-value or multi-queries.
-
parameterMetaData
protected MysqlParameterMetadata parameterMetaData
-
batchedValuesClause
protected String batchedValuesClause
-
rewrittenBatchSize
protected int rewrittenBatchSize
-
-
构造器详细资料
-
ClientPreparedStatement
protected ClientPreparedStatement(JdbcConnection conn, String db) throws SQLException
Constructor used by server-side prepared statements- 参数:
conn- the connection that created usdb- the database in use when we were created- 抛出:
SQLException- if an error occurs
-
ClientPreparedStatement
public ClientPreparedStatement(JdbcConnection conn, String sql, String db) throws SQLException
Constructor for the PreparedStatement class.- 参数:
conn- the connection creating this statementsql- the SQL for this statementdb- the database this statement should be issued against- 抛出:
SQLException- if a database error occurs.
-
ClientPreparedStatement
public ClientPreparedStatement(JdbcConnection conn, String sql, String db, QueryInfo cachedQueryInfo) throws SQLException
Creates a new PreparedStatement object.- 参数:
conn- the connection creating this statementsql- the SQL for this statementdb- the database this statement should be issued againstcachedQueryInfo- already createdQueryInfoor null.- 抛出:
SQLException- if a database access error occurs
-
-
方法详细资料
-
getInstance
protected static ClientPreparedStatement getInstance(JdbcConnection conn, String sql, String db) throws SQLException
Creates a prepared statement instance- 参数:
conn- the connection creating this statementsql- the SQL for this statementdb- the database this statement should be issued against- 返回:
- ClientPreparedStatement
- 抛出:
SQLException- if a database access error occurs
-
getInstance
protected static ClientPreparedStatement getInstance(JdbcConnection conn, String sql, String db, QueryInfo cachedQueryInfo) throws SQLException
Creates a prepared statement instance- 参数:
conn- the connection creating this statementsql- the SQL for this statementdb- the database this statement should be issued againstcachedQueryInfo- already createdQueryInfoor null.- 返回:
- ClientPreparedStatement instance
- 抛出:
SQLException- if a database access error occurs
-
initQuery
protected void initQuery()
- 覆盖:
initQuery在类中StatementImpl
-
getQueryBindings
public QueryBindings getQueryBindings()
- 指定者:
getQueryBindings在接口中JdbcPreparedStatement
-
toString
public String toString()
Returns this PreparedStatement represented as a string.
-
addBatch
public void addBatch() throws SQLException- 指定者:
addBatch在接口中PreparedStatement- 抛出:
SQLException
-
addBatch
public void addBatch(String sql) throws SQLException
- 指定者:
addBatch在接口中Statement- 覆盖:
addBatch在类中StatementImpl- 抛出:
SQLException
-
clearBatch
public void clearBatch() throws SQLException- 指定者:
clearBatch在接口中Statement- 覆盖:
clearBatch在类中StatementImpl- 抛出:
SQLException
-
clearParameters
public void clearParameters() throws SQLException- 指定者:
clearParameters在接口中PreparedStatement- 抛出:
SQLException
-
checkReadOnlySafeStatement
protected boolean checkReadOnlySafeStatement() throws SQLExceptionCheck to see if the statement is safe for read-only replicas after failover.- 返回:
- true if safe for read-only.
- 抛出:
SQLException- if a database access error occurs or this method is called on a closed PreparedStatement
-
execute
public boolean execute() throws SQLException- 指定者:
execute在接口中PreparedStatement- 抛出:
SQLException
-
executeBatchInternal
protected long[] executeBatchInternal() throws SQLException- 覆盖:
executeBatchInternal在类中StatementImpl- 抛出:
SQLException
-
executePreparedBatchAsMultiStatement
protected long[] executePreparedBatchAsMultiStatement(int batchTimeout) throws SQLExceptionRewrites the already prepared statement into a multi-statement query and executes the entire batch using this new statement.- 参数:
batchTimeout- timeout for the batch execution- 返回:
- update counts in the same fashion as executeBatch()
- 抛出:
SQLException- if a database access error occurs or this method is called on a closed PreparedStatement
-
setOneBatchedParameterSet
protected int setOneBatchedParameterSet(PreparedStatement batchedStatement, int batchedParamIndex, Object paramSet) throws SQLException
- 抛出:
SQLException
-
executeBatchedInserts
protected long[] executeBatchedInserts(int batchTimeout) throws SQLExceptionRewrites the already prepared statement into a multi-value insert statement and executes the entire batch using this new statement.- 参数:
batchTimeout- timeout for the batch execution- 返回:
- update counts in the same fashion as executeBatch()
- 抛出:
SQLException- if a database access error occurs or this method is called on a closed PreparedStatement
-
executeBatchSerially
protected long[] executeBatchSerially(int batchTimeout) throws SQLExceptionExecutes the current batch of statements by executing them one-by-one.- 参数:
batchTimeout- timeout for the batch execution- 返回:
- a list of update counts
- 抛出:
SQLException- if an error occurs
-
executeInternal
protected <M extends Message> ResultSetInternalMethods executeInternal(int maxRowsToRetrieve, M sendPacket, boolean createStreamingResultSet, boolean queryIsSelectOnly, ColumnDefinition metadata, boolean isBatch) throws SQLException
Actually execute the prepared statement. This is here so server-side PreparedStatements can re-use most of the code from this class.- 类型参数:
M- extendsMessage- 参数:
maxRowsToRetrieve- the max number of rows to returnsendPacket- the packet to sendcreateStreamingResultSet- should a 'streaming' result set be created?queryIsSelectOnly- is this query doing a SELECT?metadata- use this metadata instead of the one provided on wireisBatch- is this a batch query?- 返回:
- the results as a ResultSet
- 抛出:
SQLException- if an error occurs.
-
executeQuery
public ResultSet executeQuery() throws SQLException
- 指定者:
executeQuery在接口中PreparedStatement- 抛出:
SQLException
-
executeUpdate
public int executeUpdate() throws SQLException- 指定者:
executeUpdate在接口中PreparedStatement- 抛出:
SQLException
-
executeUpdateInternal
protected long executeUpdateInternal(boolean clearBatchedGeneratedKeysAndWarnings, boolean isBatch) throws SQLException- 抛出:
SQLException
-
executeUpdateInternal
protected long executeUpdateInternal(QueryBindings bindings, boolean isReallyBatch) throws SQLException
Added to allow batch-updates- 参数:
bindings- bindings objectisReallyBatch- is it a batched statement?- 返回:
- the update count
- 抛出:
SQLException- if a database error occurs
-
containsOnDuplicateKeyUpdate
protected boolean containsOnDuplicateKeyUpdate()
-
prepareBatchedInsertSQL
protected ClientPreparedStatement prepareBatchedInsertSQL(JdbcConnection localConn, int numBatches) throws SQLException
Returns a prepared statement for the number of batched parameters, used when re-writing batch INSERTs.- 参数:
localConn- the connection creating this statementnumBatches- number of entries in a batch- 返回:
- new ClientPreparedStatement
- 抛出:
SQLException- if a database access error occurs or this method is called on a closed PreparedStatement
-
setRetrieveGeneratedKeys
protected void setRetrieveGeneratedKeys(boolean flag) throws SQLException- 抛出:
SQLException
-
getBytesRepresentation
public byte[] getBytesRepresentation(int parameterIndex) throws SQLException- 指定者:
getBytesRepresentation在接口中JdbcPreparedStatement- 抛出:
SQLException
-
getMetaData
public ResultSetMetaData getMetaData() throws SQLException
- 指定者:
getMetaData在接口中PreparedStatement- 抛出:
SQLException
-
isResultSetProducingQuery
protected boolean isResultSetProducingQuery()
Checks if the given SQL query is a result set producing query.- 返回:
trueif the query produces a result set,falseotherwise.
-
getParameterMetaData
public ParameterMetaData getParameterMetaData() throws SQLException
- 指定者:
getParameterMetaData在接口中PreparedStatement- 抛出:
SQLException
-
getQueryInfo
public QueryInfo getQueryInfo()
- 指定者:
getQueryInfo在接口中JdbcPreparedStatement
-
isNull
public boolean isNull(int paramIndex) throws SQLException- 指定者:
isNull在接口中JdbcPreparedStatement- 抛出:
SQLException
-
realClose
public void realClose(boolean calledExplicitly, boolean closeOpenResults) throws SQLException从类复制的说明:StatementImplCloses this statement, and frees resources.- 指定者:
realClose在接口中JdbcPreparedStatement- 覆盖:
realClose在类中StatementImpl- 参数:
calledExplicitly- was this called from close()?closeOpenResults- should open result sets be closed?- 抛出:
SQLException- if an error occurs
-
getPreparedSql
public String getPreparedSql()
- 指定者:
getPreparedSql在接口中JdbcPreparedStatement
-
getUpdateCount
public int getUpdateCount() throws SQLException- 指定者:
getUpdateCount在接口中Statement- 覆盖:
getUpdateCount在类中StatementImpl- 抛出:
SQLException
-
executeLargeUpdate
public long executeLargeUpdate() throws SQLException- 指定者:
executeLargeUpdate在接口中PreparedStatement- 抛出:
SQLException
-
getParameterBindings
public ParameterBindings getParameterBindings() throws SQLException
- 指定者:
getParameterBindings在接口中JdbcPreparedStatement- 抛出:
SQLException
-
getParameterIndexOffset
protected int getParameterIndexOffset()
For calling stored functions, this will be -1 as Connector/J does not count the first '?' parameter marker, but JDBC counts it * as 1, otherwise it will return 0- 返回:
- offset
-
checkBounds
protected void checkBounds(int paramIndex, int parameterIndexOffset) throws SQLException- 抛出:
SQLException
-
getCoreParameterIndex
public final int getCoreParameterIndex(int paramIndex) throws SQLException- 抛出:
SQLException
-
setArray
public void setArray(int i, Array x) throws SQLException- 指定者:
setArray在接口中PreparedStatement- 抛出:
SQLException
-
setAsciiStream
public void setAsciiStream(int parameterIndex, InputStream x) throws SQLException- 指定者:
setAsciiStream在接口中PreparedStatement- 抛出:
SQLException
-
setAsciiStream
public void setAsciiStream(int parameterIndex, InputStream x, int length) throws SQLException- 指定者:
setAsciiStream在接口中PreparedStatement- 抛出:
SQLException
-
setAsciiStream
public void setAsciiStream(int parameterIndex, InputStream x, long length) throws SQLException- 指定者:
setAsciiStream在接口中PreparedStatement- 抛出:
SQLException
-
setBigDecimal
public void setBigDecimal(int parameterIndex, BigDecimal x) throws SQLException- 指定者:
setBigDecimal在接口中PreparedStatement- 抛出:
SQLException
-
setBinaryStream
public void setBinaryStream(int parameterIndex, InputStream x) throws SQLException- 指定者:
setBinaryStream在接口中PreparedStatement- 抛出:
SQLException
-
setBinaryStream
public void setBinaryStream(int parameterIndex, InputStream x, int length) throws SQLException- 指定者:
setBinaryStream在接口中PreparedStatement- 抛出:
SQLException
-
setBinaryStream
public void setBinaryStream(int parameterIndex, InputStream x, long length) throws SQLException- 指定者:
setBinaryStream在接口中PreparedStatement- 抛出:
SQLException
-
setBlob
public void setBlob(int i, Blob x) throws SQLException- 指定者:
setBlob在接口中PreparedStatement- 抛出:
SQLException
-
setBlob
public void setBlob(int parameterIndex, InputStream inputStream) throws SQLException- 指定者:
setBlob在接口中PreparedStatement- 抛出:
SQLException
-
setBlob
public void setBlob(int parameterIndex, InputStream inputStream, long length) throws SQLException- 指定者:
setBlob在接口中PreparedStatement- 抛出:
SQLException
-
setBoolean
public void setBoolean(int parameterIndex, boolean x) throws SQLException- 指定者:
setBoolean在接口中PreparedStatement- 抛出:
SQLException
-
setByte
public void setByte(int parameterIndex, byte x) throws SQLException- 指定者:
setByte在接口中PreparedStatement- 抛出:
SQLException
-
setBytes
public void setBytes(int parameterIndex, byte[] x) throws SQLException- 指定者:
setBytes在接口中PreparedStatement- 抛出:
SQLException
-
setBytes
public void setBytes(int parameterIndex, byte[] x, boolean escapeIfNeeded) throws SQLException- 指定者:
setBytes在接口中JdbcPreparedStatement- 抛出:
SQLException
-
setCharacterStream
public void setCharacterStream(int parameterIndex, Reader reader) throws SQLException- 指定者:
setCharacterStream在接口中PreparedStatement- 抛出:
SQLException
-
setCharacterStream
public void setCharacterStream(int parameterIndex, Reader reader, int length) throws SQLException- 指定者:
setCharacterStream在接口中PreparedStatement- 抛出:
SQLException
-
setCharacterStream
public void setCharacterStream(int parameterIndex, Reader reader, long length) throws SQLException- 指定者:
setCharacterStream在接口中PreparedStatement- 抛出:
SQLException
-
setClob
public void setClob(int parameterIndex, Reader reader) throws SQLException- 指定者:
setClob在接口中PreparedStatement- 抛出:
SQLException
-
setClob
public void setClob(int parameterIndex, Reader reader, long length) throws SQLException- 指定者:
setClob在接口中PreparedStatement- 抛出:
SQLException
-
setClob
public void setClob(int i, Clob x) throws SQLException- 指定者:
setClob在接口中PreparedStatement- 抛出:
SQLException
-
setDate
public void setDate(int parameterIndex, Date x) throws SQLException- 指定者:
setDate在接口中PreparedStatement- 抛出:
SQLException
-
setDate
public void setDate(int parameterIndex, Date x, Calendar cal) throws SQLException- 指定者:
setDate在接口中PreparedStatement- 抛出:
SQLException
-
setDouble
public void setDouble(int parameterIndex, double x) throws SQLException- 指定者:
setDouble在接口中PreparedStatement- 抛出:
SQLException
-
setFloat
public void setFloat(int parameterIndex, float x) throws SQLException- 指定者:
setFloat在接口中PreparedStatement- 抛出:
SQLException
-
setInt
public void setInt(int parameterIndex, int x) throws SQLException- 指定者:
setInt在接口中PreparedStatement- 抛出:
SQLException
-
setLong
public void setLong(int parameterIndex, long x) throws SQLException- 指定者:
setLong在接口中PreparedStatement- 抛出:
SQLException
-
setBigInteger
public void setBigInteger(int parameterIndex, BigInteger x) throws SQLException- 指定者:
setBigInteger在接口中JdbcPreparedStatement- 抛出:
SQLException
-
setNCharacterStream
public void setNCharacterStream(int parameterIndex, Reader value) throws SQLException- 指定者:
setNCharacterStream在接口中PreparedStatement- 抛出:
SQLException
-
setNCharacterStream
public void setNCharacterStream(int parameterIndex, Reader reader, long length) throws SQLException- 指定者:
setNCharacterStream在接口中PreparedStatement- 抛出:
SQLException
-
setNClob
public void setNClob(int parameterIndex, Reader reader) throws SQLException- 指定者:
setNClob在接口中PreparedStatement- 抛出:
SQLException
-
setNClob
public void setNClob(int parameterIndex, Reader reader, long length) throws SQLException- 指定者:
setNClob在接口中PreparedStatement- 抛出:
SQLException
-
setNClob
public void setNClob(int parameterIndex, NClob value) throws SQLException- 指定者:
setNClob在接口中PreparedStatement- 抛出:
SQLException
-
setNString
public void setNString(int parameterIndex, String x) throws SQLExceptionSet a parameter to a Java String value. The driver converts this to a SQL VARCHAR or LONGVARCHAR value with introducer _utf8 (depending on the arguments size relative to the driver's limits on VARCHARs) when it sends it to the database. If charset is set as utf8, this method just call setString.- 指定者:
setNString在接口中PreparedStatement- 参数:
parameterIndex- the first parameter is 1...x- the parameter value- 抛出:
SQLException- if a database access error occurs
-
setNull
public void setNull(int parameterIndex, int sqlType) throws SQLException- 指定者:
setNull在接口中PreparedStatement- 抛出:
SQLException
-
setNull
public void setNull(int parameterIndex, int sqlType, String typeName) throws SQLException- 指定者:
setNull在接口中PreparedStatement- 抛出:
SQLException
-
setNull
public void setNull(int parameterIndex, MysqlType mysqlType) throws SQLException- 指定者:
setNull在接口中JdbcPreparedStatement- 抛出:
SQLException
-
setObject
public void setObject(int parameterIndex, Object parameterObj) throws SQLException- 指定者:
setObject在接口中PreparedStatement- 抛出:
SQLException
-
setObject
public void setObject(int parameterIndex, Object parameterObj, int targetSqlType) throws SQLException- 指定者:
setObject在接口中PreparedStatement- 抛出:
SQLException
-
setObject
public void setObject(int parameterIndex, Object parameterObj, SQLType targetSqlType) throws SQLException- 指定者:
setObject在接口中PreparedStatement- 抛出:
SQLException
-
setObject
public void setObject(int parameterIndex, Object parameterObj, int targetSqlType, int scale) throws SQLException- 指定者:
setObject在接口中PreparedStatement- 抛出:
SQLException
-
setObject
public void setObject(int parameterIndex, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException- 指定者:
setObject在接口中PreparedStatement- 抛出:
SQLException
-
setRef
public void setRef(int i, Ref x) throws SQLException- 指定者:
setRef在接口中PreparedStatement- 抛出:
SQLException
-
setRowId
public void setRowId(int parameterIndex, RowId x) throws SQLException- 指定者:
setRowId在接口中PreparedStatement- 抛出:
SQLException
-
setShort
public void setShort(int parameterIndex, short x) throws SQLException- 指定者:
setShort在接口中PreparedStatement- 抛出:
SQLException
-
setSQLXML
public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException- 指定者:
setSQLXML在接口中PreparedStatement- 抛出:
SQLException
-
setString
public void setString(int parameterIndex, String x) throws SQLException- 指定者:
setString在接口中PreparedStatement- 抛出:
SQLException
-
setTime
public void setTime(int parameterIndex, Time x) throws SQLException- 指定者:
setTime在接口中PreparedStatement- 抛出:
SQLException
-
setTime
public void setTime(int parameterIndex, Time x, Calendar cal) throws SQLException- 指定者:
setTime在接口中PreparedStatement- 抛出:
SQLException
-
setTimestamp
public void setTimestamp(int parameterIndex, Timestamp x) throws SQLException- 指定者:
setTimestamp在接口中PreparedStatement- 抛出:
SQLException
-
setTimestamp
public void setTimestamp(int parameterIndex, Timestamp x, Calendar cal) throws SQLException- 指定者:
setTimestamp在接口中PreparedStatement- 抛出:
SQLException
-
setUnicodeStream
@Deprecated public void setUnicodeStream(int parameterIndex, InputStream x, int length) throws SQLException
已过时。- 指定者:
setUnicodeStream在接口中PreparedStatement- 抛出:
SQLException
-
setURL
public void setURL(int parameterIndex, URL arg) throws SQLException- 指定者:
setURL在接口中PreparedStatement- 抛出:
SQLException
-
-