public class MysqlStatementImpl
extends java.lang.Object
implements java.sql.Statement
| Modifier and Type | Method and Description |
|---|---|
void |
addBatch(java.lang.String sql) |
void |
cancel() |
void |
clearBatch() |
void |
clearWarnings() |
void |
close() |
void |
closeOnCompletion() |
boolean |
execute(java.lang.String sql)
executes the given sql.
|
boolean |
execute(java.lang.String query,
int resultType)
executes the given query with its result type.
|
boolean |
execute(java.lang.String query,
int[] columns)
executes the given query with the columns given for
primary key generation.
|
boolean |
execute(java.lang.String query,
java.lang.String[] columns)
executes the given query with the columns given for
primary key generation.
|
int[] |
executeBatch()
Executes the batched sql.
|
java.sql.ResultSet |
executeQuery(java.lang.String sql)
queries the database with the given sql.
|
int |
executeUpdate(java.lang.String sql)
updates the database with the given sql.
|
int |
executeUpdate(java.lang.String query,
int resultType)
Execute an update with the given result type.
|
int |
executeUpdate(java.lang.String query,
int[] columns)
Execute an update checking the given columns for primary keys.
|
int |
executeUpdate(java.lang.String query,
java.lang.String[] columns)
Execute an update checking the given columns for primary keys.
|
MysqlConnectionImpl |
getConnection() |
int |
getFetchDirection()
Returns the current fetch direction.
|
int |
getFetchSize()
Returns the fetch size.
|
java.sql.ResultSet |
getGeneratedKeys()
Returns the generated keys for the update.
|
int |
getMaxFieldSize()
Returns the maximum field size.
|
int |
getMaxRows()
Returns the maximum rows returned by a query.
|
boolean |
getMoreResults()
Returns true if more results are available.
|
boolean |
getMoreResults(int count)
Returns the next count results.
|
int |
getQueryTimeout()
Returns the current query timeout.
|
java.sql.ResultSet |
getResultSet() |
int |
getResultSetConcurrency()
Returns the statement's result set concurrency setting.
|
int |
getResultSetHoldability()
Returns the result set holdability.
|
int |
getResultSetType()
Returns the statement's result set type.
|
int |
getUpdateCount() |
java.sql.SQLWarning |
getWarnings()
Returns the current sql warnings.
|
boolean |
isClosed() |
boolean |
isCloseOnCompletion() |
boolean |
isPoolable() |
boolean |
isWrapperFor(java.lang.Class<?> iface) |
void |
setCursorName(java.lang.String name)
Sets the current cursor name.
|
void |
setEscapeProcessing(boolean enable)
Enables escape processing.
|
void |
setFetchDirection(int direction)
Sets the fetch direction.
|
void |
setFetchSize(int rows)
Sets the fetch size.
|
void |
setMaxFieldSize(int max)
Sets the maximum field size.
|
void |
setMaxRows(int max)
Sets the maximum rows returned by a query.
|
void |
setPoolable(boolean isPoolable) |
void |
setQueryTimeout(int seconds)
Sets the query timeout.
|
java.lang.String |
toString() |
<T> T |
unwrap(java.lang.Class<T> iface) |
public boolean execute(java.lang.String sql)
throws java.sql.SQLException
execute in interface java.sql.Statementjava.sql.SQLExceptionpublic java.sql.ResultSet executeQuery(java.lang.String sql)
throws java.sql.SQLException
executeQuery in interface java.sql.Statementjava.sql.SQLExceptionpublic int executeUpdate(java.lang.String sql)
throws java.sql.SQLException
executeUpdate in interface java.sql.Statementjava.sql.SQLExceptionpublic java.sql.ResultSet getResultSet()
throws java.sql.SQLException
getResultSet in interface java.sql.Statementjava.sql.SQLExceptionpublic int getUpdateCount()
throws java.sql.SQLException
getUpdateCount in interface java.sql.Statementjava.sql.SQLExceptionpublic MysqlConnectionImpl getConnection() throws java.sql.SQLException
getConnection in interface java.sql.Statementjava.sql.SQLExceptionpublic void clearWarnings()
throws java.sql.SQLException
clearWarnings in interface java.sql.Statementjava.sql.SQLExceptionpublic java.sql.SQLWarning getWarnings()
throws java.sql.SQLException
getWarnings in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean isClosed()
throws java.sql.SQLException
isClosed in interface java.sql.Statementjava.sql.SQLExceptionpublic void close()
throws java.sql.SQLException
close in interface java.lang.AutoCloseableclose in interface java.sql.Statementjava.sql.SQLExceptionpublic void addBatch(java.lang.String sql)
throws java.sql.SQLException
addBatch in interface java.sql.Statementjava.sql.SQLExceptionpublic void cancel()
throws java.sql.SQLException
cancel in interface java.sql.Statementjava.sql.SQLExceptionpublic void clearBatch()
throws java.sql.SQLException
clearBatch in interface java.sql.Statementjava.sql.SQLExceptionpublic int executeUpdate(java.lang.String query,
int resultType)
throws java.sql.SQLException
executeUpdate in interface java.sql.Statementjava.sql.SQLExceptionpublic int executeUpdate(java.lang.String query,
int[] columns)
throws java.sql.SQLException
executeUpdate in interface java.sql.Statementjava.sql.SQLExceptionpublic int executeUpdate(java.lang.String query,
java.lang.String[] columns)
throws java.sql.SQLException
executeUpdate in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean execute(java.lang.String query,
int resultType)
throws java.sql.SQLException
execute in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean execute(java.lang.String query,
int[] columns)
throws java.sql.SQLException
execute in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean execute(java.lang.String query,
java.lang.String[] columns)
throws java.sql.SQLException
execute in interface java.sql.Statementjava.sql.SQLExceptionpublic int[] executeBatch()
throws java.sql.SQLException
executeBatch in interface java.sql.Statementjava.sql.SQLExceptionpublic int getFetchDirection()
throws java.sql.SQLException
getFetchDirection in interface java.sql.Statementjava.sql.SQLExceptionpublic void setFetchDirection(int direction)
throws java.sql.SQLException
setFetchDirection in interface java.sql.Statementjava.sql.SQLExceptionpublic int getFetchSize()
throws java.sql.SQLException
getFetchSize in interface java.sql.Statementjava.sql.SQLExceptionpublic void setFetchSize(int rows)
throws java.sql.SQLException
setFetchSize in interface java.sql.Statementjava.sql.SQLExceptionpublic int getMaxFieldSize()
throws java.sql.SQLException
getMaxFieldSize in interface java.sql.Statementjava.sql.SQLExceptionpublic void setMaxFieldSize(int max)
throws java.sql.SQLException
setMaxFieldSize in interface java.sql.Statementjava.sql.SQLExceptionpublic int getMaxRows()
throws java.sql.SQLException
getMaxRows in interface java.sql.Statementjava.sql.SQLExceptionpublic void setMaxRows(int max)
throws java.sql.SQLException
setMaxRows in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean getMoreResults()
throws java.sql.SQLException
getMoreResults in interface java.sql.Statementjava.sql.SQLExceptionpublic int getQueryTimeout()
throws java.sql.SQLException
getQueryTimeout in interface java.sql.Statementjava.sql.SQLExceptionpublic void setQueryTimeout(int seconds)
throws java.sql.SQLException
setQueryTimeout in interface java.sql.Statementjava.sql.SQLExceptionpublic int getResultSetConcurrency()
throws java.sql.SQLException
getResultSetConcurrency in interface java.sql.Statementjava.sql.SQLExceptionpublic int getResultSetType()
throws java.sql.SQLException
getResultSetType in interface java.sql.Statementjava.sql.SQLExceptionpublic void setCursorName(java.lang.String name)
throws java.sql.SQLException
setCursorName in interface java.sql.Statementjava.sql.SQLExceptionpublic void setEscapeProcessing(boolean enable)
throws java.sql.SQLException
setEscapeProcessing in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean getMoreResults(int count)
throws java.sql.SQLException
getMoreResults in interface java.sql.Statementjava.sql.SQLExceptionpublic java.sql.ResultSet getGeneratedKeys()
throws java.sql.SQLException
getGeneratedKeys in interface java.sql.Statementjava.sql.SQLExceptionpublic int getResultSetHoldability()
throws java.sql.SQLException
getResultSetHoldability in interface java.sql.Statementjava.sql.SQLExceptionpublic <T> T unwrap(java.lang.Class<T> iface)
throws java.sql.SQLException
unwrap in interface java.sql.Wrapperjava.sql.SQLExceptionpublic boolean isWrapperFor(java.lang.Class<?> iface)
throws java.sql.SQLException
isWrapperFor in interface java.sql.Wrapperjava.sql.SQLExceptionpublic boolean isPoolable()
isPoolable in interface java.sql.Statementpublic void setPoolable(boolean isPoolable)
setPoolable in interface java.sql.Statementpublic void closeOnCompletion()
throws java.sql.SQLException
closeOnCompletion in interface java.sql.Statementjava.sql.SQLExceptionpublic boolean isCloseOnCompletion()
throws java.sql.SQLException
isCloseOnCompletion in interface java.sql.Statementjava.sql.SQLExceptionpublic java.lang.String toString()
toString in class java.lang.Object