| java.lang.Object com.sqlmagic.tinysql.tinySQLPreparedStatement
tinySQLPreparedStatement | public class tinySQLPreparedStatement implements java.sql.PreparedStatement(Code) | | author: Thomas Morgner statementString contains the last author: used SQL-Query. Support for set/getFetchSize, ResultSets are created with a author: reference to the creating statement |
Method Summary | |
public void | addBatch() JDBC 2.0
Adds a SQL command to the current batch of commmands for the statement. | public void | addBatch(String sql) | public void | addTable(tinySQLTable inputTable) | public void | cancel() This can be used by another thread to cancel a statement. | public void | clearBatch() JDBC 2.0
Makes the set of commands in the current batch empty. | public void | clearParameters() | public void | clearWarnings() | public void | close() Close any result sets. | public boolean | execute() Executes some SQL and returns true or false, depending on
the success. | public boolean | execute(String sql) | public int[] | executeBatch() JDBC 2.0
Submits a batch of commands to the database for execution.
This method is optional.
an array of update counts containing one element for eachcommand in the batch. | public synchronized ResultSet | executeQuery() Execute an SQL statement and return a result set. | public synchronized ResultSet | executeQuery(String sql) | public synchronized int | executeUpdate(String sql) Execute an update, insert, delete, create table, etc. | public synchronized int | executeUpdate() | public Vector | getActions() | public Connection | getConnection() JDBC 2.0
Returns the Connection object
that produced this Statement object. | public int | getFetchDirection() JDBC 2.0
Retrieves the direction for fetching rows from
database tables that is the default for result sets
generated from this Statement object. | public int | getFetchSize() JDBC 2.0
Retrieves the number of result set rows that is the default
fetch size for result sets
generated from this Statement object. | public int | getMaxFieldSize() Get the maximum field size to return in a result set. | public int | getMaxRows() Get the maximum row count that can be returned by a result set. | public ResultSetMetaData | getMetaData() | public boolean | getMoreResults() This returns true if there are any pending result sets. | public int | getQueryTimeout() Discover the query timeout. | public ResultSet | getResultSet() | public int | getResultSetConcurrency() JDBC 2.0
Retrieves the result set concurrency. | public int | getResultSetType() JDBC 2.0
Determine the result set type. | public String | getSQLString() | public int | getUpdateCount() Return the row count of the last operation. | final public SQLWarning | getWarnings() | public void | setArray(int parameterIndex, java.sql.Array inputValue) | public void | setAsciiStream(int parameterIndex, java.io.InputStream inputValue, int streamLength) | public void | setBigDecimal(int parameterIndex, BigDecimal inputValue) | public void | setBinaryStream(int parameterIndex, java.io.InputStream inputValue, int streamLength) | public void | setBlob(int parameterIndex, java.sql.Blob inputValue) | public void | setBoolean(int parameterIndex, boolean inputValue) | public void | setByte(int parameterIndex, byte inputValue) | public void | setBytes(int parameterIndex, byte[] inputValue) | public void | setCharacterStream(int parameterIndex, java.io.Reader inputValue, int streamLength) | public void | setClob(int parameterIndex, java.sql.Clob inputValue) | public void | setCursorName(String unused) Sets the cursor name for this connection. | public void | setDate(int parameterIndex, java.sql.Date inputValue, java.util.Calendar inputCalendar) | public void | setDate(int parameterIndex, java.sql.Date inputValue) | public void | setDouble(int parameterIndex, double inputValue) | public void | setEscapeProcessing(boolean enable) If escape scanning is on (the default) the driver will do
escape substitution before sending the SQL to the database. | public void | setFetchDirection(int direction) JDBC 2.0
Gives the driver a hint as to the direction in which
the rows in a result set
will be processed. | public void | setFetchSize(int rows) JDBC 2.0
Gives the JDBC driver a hint as to the number of rows that should
be fetched from the database when more rows are needed. | public void | setFloat(int parameterIndex, float inputValue) | public void | setInt(int parameterIndex, int inputValue) | public void | setLong(int parameterIndex, long inputValue) | public void | setMaxFieldSize(int max) set the max field size. | public void | setMaxRows(int max) Get the maximum row count that can be returned by a result set. | public void | setNull(int parameterIndex, int sqlType) | public void | setNull(int parameterIndex, int sqlType, String sqlTypeName) | public void | setObject(int parameterIndex, Object inputValue) | public void | setObject(int parameterIndex, Object inputValue, int targetSQLType) | public void | setObject(int parameterIndex, Object inputValue, int targetSQLType, int scale) | public void | setQueryTimeout(int x) Set the query timeout. | public void | setRef(int parameterIndex, java.sql.Ref inputValue) | public void | setShort(int parameterIndex, short inputValue) | public void | setString(int parameterIndex, String setString) | public void | setTime(int parameterIndex, java.sql.Time inputValue, java.util.Calendar inputCalendar) | public void | setTime(int parameterIndex, java.sql.Time inputValue) | public void | setTimestamp(int parameterIndex, java.sql.Timestamp inputValue, java.util.Calendar inputCalendar) | public void | setTimestamp(int parameterIndex, java.sql.Timestamp inputValue) | public void | setUnicodeStream(int parameterIndex, java.io.InputStream inputValue, int streamLength) | public void | updateActions(Vector inputActions) |
tinySQLPreparedStatement | public tinySQLPreparedStatement(tinySQLConnection conn, String inputString)(Code) | | Constructs a new tinySQLStatement object.
Parameters: conn - the tinySQLConnection object |
addBatch | public void addBatch() throws SQLException(Code) | | JDBC 2.0
Adds a SQL command to the current batch of commmands for the statement.
This method is optional.
Parameters: sql - typically this is a static SQL INSERT or UPDATE statement exception: SQLException - if a database access error occurs, or thedriver does not support batch statements |
clearBatch | public void clearBatch() throws SQLException(Code) | | JDBC 2.0
Makes the set of commands in the current batch empty.
This method is optional.
exception: SQLException - if a database access error occurs or thedriver does not support batch statements |
execute | public boolean execute() throws SQLException(Code) | | Executes some SQL and returns true or false, depending on
the success. The result set is stored in result, and can
be retrieved with getResultSet();
See Also: java.sql.PreparedStatement.execute exception: SQLException - raised for any errors Parameters: sql - the SQL to be executed true if there is a result set available |
executeBatch | public int[] executeBatch() throws SQLException(Code) | | JDBC 2.0
Submits a batch of commands to the database for execution.
This method is optional.
an array of update counts containing one element for eachcommand in the batch. The array is ordered according to the order in which commands were inserted into the batch. exception: SQLException - if a database access error occurs or thedriver does not support batch statements |
getConnection | public Connection getConnection() throws SQLException(Code) | | JDBC 2.0
Returns the Connection object
that produced this Statement object.
the connection that produced this statement exception: SQLException - if a database access error occurs |
getFetchDirection | public int getFetchDirection() throws SQLException(Code) | | JDBC 2.0
Retrieves the direction for fetching rows from
database tables that is the default for result sets
generated from this Statement object.
If this Statement object has not set
a fetch direction by calling the method setFetchDirection ,
the return value is implementation-specific.
the default fetch direction for result sets generatedfrom this Statement object exception: SQLException - if a database access error occurs |
getFetchSize | public int getFetchSize() throws SQLException(Code) | | JDBC 2.0
Retrieves the number of result set rows that is the default
fetch size for result sets
generated from this Statement object.
If this Statement object has not set
a fetch size by calling the method setFetchSize ,
the return value is implementation-specific.
the default fetch size for result sets generatedfrom this Statement object exception: SQLException - if a database access error occurs |
getResultSetConcurrency | public int getResultSetConcurrency() throws SQLException(Code) | | JDBC 2.0
Retrieves the result set concurrency.
|
getResultSetType | public int getResultSetType() throws SQLException(Code) | | JDBC 2.0
Determine the result set type.
|
getSQLString | public String getSQLString()(Code) | | Returns the current query-String
|
setBoolean | public void setBoolean(int parameterIndex, boolean inputValue) throws SQLException(Code) | | |
setBytes | public void setBytes(int parameterIndex, byte[] inputValue) throws SQLException(Code) | | |
setCursorName | public void setCursorName(String unused) throws SQLException(Code) | | Sets the cursor name for this connection. Presently unsupported.
|
setDouble | public void setDouble(int parameterIndex, double inputValue) throws SQLException(Code) | | |
setFetchDirection | public void setFetchDirection(int direction) throws SQLException(Code) | | JDBC 2.0
Gives the driver a hint as to the direction in which
the rows in a result set
will be processed. The hint applies only to result sets created
using this Statement object. The default value is
ResultSet.FETCH_FORWARD.
Note that this method sets the default fetch direction for
result sets generated by this Statement object.
Each result set has its own methods for getting and setting
its own fetch direction.
Parameters: direction - the initial direction for processing rows exception: SQLException - if a database access error occursor the given directionis not one of ResultSet.FETCH_FORWARD, ResultSet.FETCH_REVERSE, orResultSet.FETCH_UNKNOWN |
setFetchSize | public void setFetchSize(int rows) throws SQLException(Code) | | JDBC 2.0
Gives the JDBC driver a hint as to the number of rows that should
be fetched from the database when more rows are needed. The number
of rows specified affects only result sets created using this
statement. If the value specified is zero, then the hint is ignored.
The default value is zero.
Parameters: rows - the number of rows to fetch exception: SQLException - if a database access error occurs, or thecondition 0 <= rows <= this.getMaxRows() is not satisfied. |
setFloat | public void setFloat(int parameterIndex, float inputValue) throws SQLException(Code) | | |
setMaxRows | public void setMaxRows(int max) throws SQLException(Code) | | Get the maximum row count that can be returned by a result set.
See Also: java.sql.PreparedStatement.setMaxRows Parameters: max - the max rows |
setObject | public void setObject(int parameterIndex, Object inputValue, int targetSQLType, int scale) throws SQLException(Code) | | |
setShort | public void setShort(int parameterIndex, short inputValue) throws SQLException(Code) | | |
|
|