|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--com.cafesoft.core.jdbc.ResultSetHolder
|
+--com.cafesoft.core.jdbc.DelegatingCallableStatement
The DelegatingCallableStatement Object implements the java.sql.CallableStatement interface. The DelegatingCallableStatement proxies all method calls made to the CallableStatement interface to an underlying CallableStatement implementation.
Statement,
CallableStatement| Field Summary |
| Fields inherited from interface java.sql.Statement |
CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, EXECUTE_FAILED, KEEP_CURRENT_RESULT, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO |
| Constructor Summary | |
DelegatingCallableStatement(Connection conn,
CallableStatement stmt)
Create a new DelegatingCallableStatement object |
|
| Method Summary | |
protected void |
activate()
Activate the Statement object This method simply sets the state of the Statement to that of the ready state. |
void |
addBatch()
Adds a set of parameters to this PreparedStatement
object's batch of commands. |
void |
addBatch(String sql)
Adds the given SQL command to the current list of commmands for this Statement object. |
void |
addResultSet(ResultSet set)
Add a ResultSet Object to the ResultSetHolder |
void |
cancel()
Cancels this Statement object if both the DBMS and
driver support aborting an SQL statement.
|
protected void |
checkOpen()
Determine if the Statement is open or closed |
void |
clearBatch()
Empties this Statement object's current list of
SQL commands.
|
void |
clearParameters()
Clears the current parameter values immediately. |
void |
clearWarnings()
Clears all the warnings reported on this Statement
object. |
void |
close()
Releases this Statement object's database
and JDBC resources immediately instead of waiting for
this to happen when it is automatically closed.
|
boolean |
execute()
Executes the SQL statement in this PreparedStatement object,
which may be any kind of SQL statement.
|
boolean |
execute(String sql)
Executes the given SQL statement, which may return multiple results. |
boolean |
execute(String sql,
int autoGeneratedKeys)
Executes the given SQL statement, which may return multiple results, and signals the driver that any auto-generated keys should be made available for retrieval. |
boolean |
execute(String sql,
int[] columnIndexes)
Executes the given SQL statement, which may return multiple results, and signals the driver that the auto-generated keys indicated in the given array should be made available for retrieval. |
boolean |
execute(String sql,
String[] columnNames)
Executes the given SQL statement, which may return multiple results, and signals the driver that the auto-generated keys indicated in the given array should be made available for retrieval. |
int[] |
executeBatch()
Submits a batch of commands to the database for execution and if all commands execute successfully, returns an array of update counts. |
ResultSet |
executeQuery()
Executes the SQL query in this PreparedStatement object
and returns the ResultSet object generated by the query. |
ResultSet |
executeQuery(String sql)
Executes the given SQL statement, which returns a single ResultSet object. |
int |
executeUpdate()
Executes the SQL statement in this PreparedStatement object,
which must be an SQL INSERT, UPDATE or
DELETE statement; or an SQL statement that returns nothing,
such as a DDL statement. |
int |
executeUpdate(String sql)
Executes the given SQL statement, which may be an INSERT,
UPDATE, or DELETE statement or an
SQL statement that returns nothing, such as an SQL DDL statement. |
int |
executeUpdate(String sql,
int autoGeneratedKeys)
Executes the given SQL statement and signals the driver with the given flag about whether the auto-generated keys produced by this Statement object
should be made available for retrieval. |
int |
executeUpdate(String sql,
int[] columnIndexes)
Executes the given SQL statement and signals the driver that the auto-generated keys indicated in the given array should be made available for retrieval. |
int |
executeUpdate(String sql,
String[] columnNames)
Executes the given SQL statement and signals the driver that the auto-generated keys indicated in the given array should be made available for retrieval. |
Array |
getArray(int i)
Retrieves the value of the designated JDBC ARRAY parameter as an
Array object in the Java programming language. |
Array |
getArray(String parameterName)
Retrieves the value of a JDBC ARRAY parameter as an
Array object in the Java programming language. |
BigDecimal |
getBigDecimal(int parameterIndex)
Retrieves the value of the designated JDBC NUMERIC parameter as a
java.math.BigDecimal object with as many digits to the
right of the decimal point as the value contains. |
BigDecimal |
getBigDecimal(int parameterIndex,
int scale)
Deprecated. use getBigDecimal(int parameterIndex)
or getBigDecimal(String parameterName) |
BigDecimal |
getBigDecimal(String parameterName)
Retrieves the value of a JDBC NUMERIC parameter as a
java.math.BigDecimal object with as many digits to the
right of the decimal point as the value contains. |
Blob |
getBlob(int i)
Retrieves the value of the designated JDBC BLOB parameter as a
Blob object in the Java programming language. |
Blob |
getBlob(String parameterName)
Retrieves the value of a JDBC BLOB parameter as a
Blob object in the Java programming language. |
boolean |
getBoolean(int parameterIndex)
Retrieves the value of the designated JDBC BIT parameter as a
boolean in the Java programming language. |
boolean |
getBoolean(String parameterName)
Retrieves the value of a JDBC BIT parameter as a
boolean in the Java programming language. |
byte |
getByte(int parameterIndex)
Retrieves the value of the designated JDBC TINYINT parameter
as a byte in the Java programming language. |
byte |
getByte(String parameterName)
Retrieves the value of a JDBC TINYINT parameter as a byte
in the Java programming language. |
byte[] |
getBytes(int parameterIndex)
Retrieves the value of the designated JDBC BINARY or
VARBINARY parameter as an array of byte
values in the Java programming language. |
byte[] |
getBytes(String parameterName)
Retrieves the value of a JDBC BINARY or VARBINARY
parameter as an array of byte values in the Java
programming language. |
Clob |
getClob(int i)
Retrieves the value of the designated JDBC CLOB parameter as a
Clob object in the Java programming language. |
Clob |
getClob(String parameterName)
Retrieves the value of a JDBC CLOB parameter as a
Clob object in the Java programming language. |
Connection |
getConnection()
Retrieves the Connection object
that produced this Statement object. |
Date |
getDate(int parameterIndex)
Retrieves the value of the designated JDBC DATE parameter as a
java.sql.Date object. |
Date |
getDate(int parameterIndex,
Calendar cal)
Retrieves the value of the designated JDBC DATE parameter as a
java.sql.Date object, using
the given Calendar object
to construct the date.
|
Date |
getDate(String parameterName)
Retrieves the value of a JDBC DATE parameter as a
java.sql.Date object. |
Date |
getDate(String parameterName,
Calendar cal)
Retrieves the value of a JDBC DATE parameter as a
java.sql.Date object, using
the given Calendar object
to construct the date.
|
double |
getDouble(int parameterIndex)
Retrieves the value of the designated JDBC DOUBLE parameter as a double
in the Java programming language. |
double |
getDouble(String parameterName)
Retrieves the value of a JDBC DOUBLE parameter as a double
in the Java programming language. |
int |
getFetchDirection()
Retrieves the direction for fetching rows from database tables that is the default for result sets generated from this Statement object.
|
int |
getFetchSize()
Retrieves the number of result set rows that is the default fetch size for ResultSet objects
generated from this Statement object.
|
float |
getFloat(int parameterIndex)
Retrieves the value of the designated JDBC FLOAT parameter
as a float in the Java programming language. |
float |
getFloat(String parameterName)
Retrieves the value of a JDBC FLOAT parameter as a float
in the Java programming language. |
ResultSet |
getGeneratedKeys()
Retrieves any auto-generated keys created as a result of executing this Statement object. |
int |
getInt(int parameterIndex)
Retrieves the value of the designated JDBC INTEGER parameter
as an int in the Java programming language. |
int |
getInt(String parameterName)
Retrieves the value of a JDBC INTEGER parameter as an int
in the Java programming language. |
long |
getLong(int parameterIndex)
Retrieves the value of the designated JDBC BIGINT parameter
as a long in the Java programming language. |
long |
getLong(String parameterName)
Retrieves the value of a JDBC BIGINT parameter as a long
in the Java programming language. |
int |
getMaxFieldSize()
Retrieves the maximum number of bytes that can be returned for character and binary column values in a ResultSet
object produced by this Statement object.
|
int |
getMaxRows()
Retrieves the maximum number of rows that a ResultSet object produced by this
Statement object can contain. |
ResultSetMetaData |
getMetaData()
Retrieves a ResultSetMetaData object that contains
information about the columns of the ResultSet object
that will be returned when this PreparedStatement object
is executed.
|
boolean |
getMoreResults()
Moves to this Statement object's next result, returns
true if it is a ResultSet object, and
implicitly closes any current ResultSet
object(s) obtained with the method getResultSet.
|
boolean |
getMoreResults(int current)
Moves to this Statement object's next result, deals with
any current ResultSet object(s) according to the instructions
specified by the given flag, and returns
true if the next result is a ResultSet object.
|
Object |
getObject(int parameterIndex)
Retrieves the value of the designated parameter as an Object
in the Java programming language. |
Object |
getObject(int i,
Map map)
Returns an object representing the value of OUT parameter i and uses map for the custom
mapping of the parameter value.
|
Object |
getObject(String parameterName)
Retrieves the value of a parameter as an Object in the Java
programming language. |
Object |
getObject(String parameterName,
Map map)
Returns an object representing the value of OUT parameter i and uses map for the custom
mapping of the parameter value.
|
ParameterMetaData |
getParameterMetaData()
Retrieves the number, types and properties of this PreparedStatement object's parameters. |
int |
getQueryTimeout()
Retrieves the number of seconds the driver will wait for a Statement object to execute. |
Ref |
getRef(int i)
Retrieves the value of the designated JDBC REF(<structured-type>)
parameter as a Ref object in the Java programming language. |
Ref |
getRef(String parameterName)
Retrieves the value of a JDBC REF(<structured-type>)
parameter as a Ref object in the Java programming language. |
ResultSet |
getResultSet()
Retrieves the current result as a ResultSet object.
|
int |
getResultSetConcurrency()
Retrieves the result set concurrency for ResultSet objects
generated by this Statement object. |
int |
getResultSetHoldability()
Retrieves the result set holdability for ResultSet objects
generated by this Statement object. |
ResultSet[] |
getResultSets()
Get all of the ResultSets contained by the Holder |
int |
getResultSetType()
Retrieves the result set type for ResultSet objects
generated by this Statement object. |
short |
getShort(int parameterIndex)
Retrieves the value of the designated JDBC SMALLINT parameter
as a short in the Java programming language. |
short |
getShort(String parameterName)
Retrieves the value of a JDBC SMALLINT parameter as a short
in the Java programming language. |
String |
getString(int parameterIndex)
Retrieves the value of the designated JDBC CHAR,
VARCHAR, or LONGVARCHAR parameter as a
String in the Java programming language.
|
String |
getString(String parameterName)
Retrieves the value of a JDBC CHAR, VARCHAR,
or LONGVARCHAR parameter as a String in
the Java programming language.
|
Time |
getTime(int parameterIndex)
Retrieves the value of the designated JDBC TIME parameter as a
java.sql.Time object. |
Time |
getTime(int parameterIndex,
Calendar cal)
Retrieves the value of the designated JDBC TIME parameter as a
java.sql.Time object, using
the given Calendar object
to construct the time.
|
Time |
getTime(String parameterName)
Retrieves the value of a JDBC TIME parameter as a
java.sql.Time object. |
Time |
getTime(String parameterName,
Calendar cal)
Retrieves the value of a JDBC TIME parameter as a
java.sql.Time object, using
the given Calendar object
to construct the time.
|
Timestamp |
getTimestamp(int parameterIndex)
Retrieves the value of the designated JDBC TIMESTAMP parameter as a
java.sql.Timestamp object. |
Timestamp |
getTimestamp(int parameterIndex,
Calendar cal)
Retrieves the value of the designated JDBC TIMESTAMP parameter as a
java.sql.Timestamp object, using
the given Calendar object to construct
the Timestamp object.
|
Timestamp |
getTimestamp(String parameterName)
Retrieves the value of a JDBC TIMESTAMP parameter as a
java.sql.Timestamp object. |
Timestamp |
getTimestamp(String parameterName,
Calendar cal)
Retrieves the value of a JDBC TIMESTAMP parameter as a
java.sql.Timestamp object, using
the given Calendar object to construct
the Timestamp object.
|
int |
getUpdateCount()
Retrieves the current result as an update count; if the result is a ResultSet object or there are no more results, -1
is returned. |
URL |
getURL(int parameterIndex)
Retrieves the value of the designated JDBC DATALINK parameter as a
java.net.URL object. |
URL |
getURL(String parameterName)
Retrieves the value of a JDBC DATALINK parameter as a
java.net.URL object. |
SQLWarning |
getWarnings()
Retrieves the first warning reported by calls on this Statement object.
|
protected void |
passivate()
Passivate the Statement Object This method sets the state of the Statement object to a state of inactive. |
void |
registerOutParameter(int parameterIndex,
int sqlType)
Registers the OUT parameter in ordinal position parameterIndex to the JDBC type
sqlType. |
void |
registerOutParameter(int parameterIndex,
int sqlType,
int scale)
Registers the parameter in ordinal position parameterIndex to be of JDBC type
sqlType. |
void |
registerOutParameter(int paramIndex,
int sqlType,
String typeName)
Registers the designated output parameter. |
void |
registerOutParameter(String parameterName,
int sqlType)
Registers the OUT parameter named parameterName to the JDBC type
sqlType. |
void |
registerOutParameter(String parameterName,
int sqlType,
int scale)
Registers the parameter named parameterName to be of JDBC type
sqlType. |
void |
registerOutParameter(String parameterName,
int sqlType,
String typeName)
Registers the designated output parameter. |
void |
removeResultSet(ResultSet set)
Remove a ResultSet Object to the ResultSetHolder |
void |
setArray(int i,
Array x)
Sets the designated parameter to the given Array object.
|
void |
setAsciiStream(int parameterIndex,
InputStream x,
int length)
Sets the designated parameter to the given input stream, which will have the specified number of bytes. |
void |
setAsciiStream(String parameterName,
InputStream x,
int length)
Sets the designated parameter to the given input stream, which will have the specified number of bytes. |
void |
setBigDecimal(int parameterIndex,
BigDecimal x)
Sets the designated parameter to the given java.math.BigDecimal value.
|
void |
setBigDecimal(String parameterName,
BigDecimal x)
Sets the designated parameter to the given java.math.BigDecimal value.
|
void |
setBinaryStream(int parameterIndex,
InputStream x,
int length)
Sets the designated parameter to the given input stream, which will have the specified number of bytes. |
void |
setBinaryStream(String parameterName,
InputStream x,
int length)
Sets the designated parameter to the given input stream, which will have the specified number of bytes. |
void |
setBlob(int i,
Blob x)
Sets the designated parameter to the given Blob object.
|
void |
setBoolean(int parameterIndex,
boolean x)
Sets the designated parameter to the given Java boolean value.
|
void |
setBoolean(String parameterName,
boolean x)
Sets the designated parameter to the given Java boolean value.
|
void |
setByte(int parameterIndex,
byte x)
Sets the designated parameter to the given Java byte value.
|
void |
setByte(String parameterName,
byte x)
Sets the designated parameter to the given Java byte value.
|
void |
setBytes(int parameterIndex,
byte[] x)
Sets the designated parameter to the given Java array of bytes. |
void |
setBytes(String parameterName,
byte[] x)
Sets the designated parameter to the given Java array of bytes. |
void |
setCharacterStream(int parameterIndex,
Reader reader,
int length)
Sets the designated parameter to the given Reader
object, which is the given number of characters long.
|
void |
setCharacterStream(String parameterName,
Reader reader,
int length)
Sets the designated parameter to the given Reader
object, which is the given number of characters long.
|
void |
setClob(int i,
Clob x)
Sets the designated parameter to the given Clob object.
|
void |
setCursorName(String name)
Sets the SQL cursor name to the given String, which
will be used by subsequent Statement object
execute methods. |
void |
setDate(int parameterIndex,
Date x)
Sets the designated parameter to the given java.sql.Date value.
|
void |
setDate(int parameterIndex,
Date x,
Calendar cal)
Sets the designated parameter to the given java.sql.Date value,
using the given Calendar object. |
void |
setDate(String parameterName,
Date x)
Sets the designated parameter to the given java.sql.Date value.
|
void |
setDate(String parameterName,
Date x,
Calendar cal)
Sets the designated parameter to the given java.sql.Date value,
using the given Calendar object. |
void |
setDouble(int parameterIndex,
double x)
Sets the designated parameter to the given Java double value.
|
void |
setDouble(String parameterName,
double x)
Sets the designated parameter to the given Java double value.
|
void |
setEscapeProcessing(boolean enable)
Sets escape processing on or off. |
void |
setFetchDirection(int direction)
Gives the driver a hint as to the direction in which rows will be processed in ResultSet
objects created using this Statement object. |
void |
setFetchSize(int rows)
Gives the JDBC driver a hint as to the number of rows that should be fetched from the database when more rows are needed. |
void |
setFloat(int parameterIndex,
float x)
Sets the designated parameter to the given Java float value.
|
void |
setFloat(String parameterName,
float x)
Sets the designated parameter to the given Java float value.
|
void |
setInt(int parameterIndex,
int x)
Sets the designated parameter to the given Java int value.
|
void |
setInt(String parameterName,
int x)
Sets the designated parameter to the given Java int value.
|
void |
setLong(int parameterIndex,
long x)
Sets the designated parameter to the given Java long value.
|
void |
setLong(String parameterName,
long x)
Sets the designated parameter to the given Java long value.
|
void |
setMaxFieldSize(int max)
Sets the limit for the maximum number of bytes in a ResultSet
column storing character or binary values to
the given number of bytes. |
void |
setMaxRows(int max)
Sets the limit for the maximum number of rows that any ResultSet object can contain to the given number.
|
void |
setNull(int parameterIndex,
int sqlType)
Sets the designated parameter to SQL NULL.
|
void |
setNull(int paramIndex,
int sqlType,
String typeName)
Sets the designated parameter to SQL NULL.
|
void |
setNull(String parameterName,
int sqlType)
Sets the designated parameter to SQL NULL.
|
void |
setNull(String parameterName,
int sqlType,
String typeName)
Sets the designated parameter to SQL NULL.
|
void |
setObject(int parameterIndex,
Object x)
Sets the value of the designated parameter using the given object. |
void |
setObject(int parameterIndex,
Object x,
int targetSqlType)
Sets the value of the designated parameter with the given object. |
void |
setObject(int parameterIndex,
Object x,
int targetSqlType,
int scale)
Sets the value of the designated parameter with the given object. |
void |
setObject(String parameterName,
Object x)
Sets the value of the designated parameter with the given object. |
void |
setObject(String parameterName,
Object x,
int targetSqlType)
Sets the value of the designated parameter with the given object. |
void |
setObject(String parameterName,
Object x,
int targetSqlType,
int scale)
Sets the value of the designated parameter with the given object. |
void |
setQueryTimeout(int seconds)
Sets the number of seconds the driver will wait for a Statement object to execute to the given number of seconds.
|
void |
setRef(int i,
Ref x)
Sets the designated parameter to the given REF(<structured-type>) value.
|
void |
setShort(int parameterIndex,
short x)
Sets the designated parameter to the given Java short value.
|
void |
setShort(String parameterName,
short x)
Sets the designated parameter to the given Java short value.
|
void |
setString(int parameterIndex,
String x)
Sets the designated parameter to the given Java String value.
|
void |
setString(String parameterName,
String x)
Sets the designated parameter to the given Java String value.
|
void |
setTime(int parameterIndex,
Time x)
Sets the designated parameter to the given java.sql.Time value.
|
void |
setTime(int parameterIndex,
Time x,
Calendar cal)
Sets the designated parameter to the given java.sql.Time value,
using the given Calendar object. |
void |
setTime(String parameterName,
Time x)
Sets the designated parameter to the given java.sql.Time value.
|
void |
setTime(String parameterName,
Time x,
Calendar cal)
Sets the designated parameter to the given java.sql.Time value,
using the given Calendar object. |
void |
setTimestamp(int parameterIndex,
Timestamp x)
Sets the designated parameter to the given java.sql.Timestamp value.
|
void |
setTimestamp(int parameterIndex,
Timestamp x,
Calendar cal)
Sets the designated parameter to the given java.sql.Timestamp value,
using the given Calendar object. |
void |
setTimestamp(String parameterName,
Timestamp x)
Sets the designated parameter to the given java.sql.Timestamp value.
|
void |
setTimestamp(String parameterName,
Timestamp x,
Calendar cal)
Sets the designated parameter to the given java.sql.Timestamp value,
using the given Calendar object. |
void |
setUnicodeStream(int parameterIndex,
InputStream x,
int length)
Deprecated. |
void |
setURL(int parameterIndex,
URL x)
Sets the designated parameter to the given java.net.URL value.
|
void |
setURL(String parameterName,
URL val)
Sets the designated parameter to the given java.net.URL object.
|
boolean |
wasNull()
Retrieves whether the last OUT parameter read had the value of SQL NULL. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DelegatingCallableStatement(Connection conn,
CallableStatement stmt)
conn - the Connection that created the Statementstmt - the underlying CallableStatement object through which
all method calls are delegated to.| Method Detail |
protected void activate()
This method simply sets the state of the Statement to that of the ready state.
protected void passivate()
throws SQLException
This method sets the state of the Statement object to a state of inactive. The idea being that the Statement is no longer valid to use. This method is generally called in cases where the Statement object is about to be closed.
SQLException - thrown if a SQLException occurs closing
open Statement objects
protected void checkOpen()
throws SQLException
SQLException - thrown if the Statement is closed
public void registerOutParameter(int parameterIndex,
int sqlType)
throws SQLException
parameterIndex to the JDBC type
sqlType. All OUT parameters must be registered
before a stored procedure is executed.
The JDBC type specified by sqlType for an OUT
parameter determines the Java type that must be used
in the get method to read the value of that parameter.
If the JDBC type expected to be returned to this output parameter
is specific to this particular database, sqlType
should be java.sql.Types.OTHER. The method
getObject(int) retrieves the value.
registerOutParameter in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so onsqlType - the JDBC type code defined by java.sql.Types.
If the parameter is of JDBC type NUMERIC
or DECIMAL, the version of
registerOutParameter that accepts a scale value
should be used.
SQLException - if a database access error occursTypes
public void registerOutParameter(int parameterIndex,
int sqlType,
int scale)
throws SQLException
parameterIndex to be of JDBC type
sqlType. This method must be called
before a stored procedure is executed.
The JDBC type specified by sqlType for an OUT
parameter determines the Java type that must be used
in the get method to read the value of that parameter.
This version of registerOutParameter should be
used when the parameter is of JDBC type NUMERIC
or DECIMAL.
registerOutParameter in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so onsqlType - the SQL type code defined by java.sql.Types.scale - the desired number of digits to the right of the
decimal point. It must be greater than or equal to zero.
SQLException - if a database access error occursTypes
public boolean wasNull()
throws SQLException
NULL. Note that this method should be called only after
calling a getter method; otherwise, there is no value to use in
determining whether it is null or not.
wasNull in interface CallableStatementtrue if the last parameter read was SQL
NULL; false otherwise
SQLException - if a database access error occurs
public String getString(int parameterIndex)
throws SQLException
CHAR,
VARCHAR, or LONGVARCHAR parameter as a
String in the Java programming language.
For the fixed-length type JDBC CHAR,
the String object
returned has exactly the same value the JDBC
CHAR value had in the
database, including any padding added by the database.
getString in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL,
the result
is null.
SQLException - if a database access error occurssetString(java.lang.String, java.lang.String)
public boolean getBoolean(int parameterIndex)
throws SQLException
BIT parameter as a
boolean in the Java programming language.
getBoolean in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL,
the result is false.
SQLException - if a database access error occurssetBoolean(java.lang.String, boolean)
public byte getByte(int parameterIndex)
throws SQLException
TINYINT parameter
as a byte in the Java programming language.
getByte in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetByte(java.lang.String, byte)
public short getShort(int parameterIndex)
throws SQLException
SMALLINT parameter
as a short in the Java programming language.
getShort in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetShort(java.lang.String, short)
public int getInt(int parameterIndex)
throws SQLException
INTEGER parameter
as an int in the Java programming language.
getInt in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetInt(java.lang.String, int)
public long getLong(int parameterIndex)
throws SQLException
BIGINT parameter
as a long in the Java programming language.
getLong in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetLong(java.lang.String, long)
public float getFloat(int parameterIndex)
throws SQLException
FLOAT parameter
as a float in the Java programming language.
getFloat in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetFloat(java.lang.String, float)
public double getDouble(int parameterIndex)
throws SQLException
DOUBLE parameter as a double
in the Java programming language.
getDouble in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is 0.
SQLException - if a database access error occurssetDouble(java.lang.String, double)
public BigDecimal getBigDecimal(int parameterIndex,
int scale)
throws SQLException
getBigDecimal(int parameterIndex)
or getBigDecimal(String parameterName)
NUMERIC parameter as a
java.math.BigDecimal object with scale digits to
the right of the decimal point.
getBigDecimal in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so onscale - the number of digits to the right of the decimal point
NULL, the result
is null.
SQLException - if a database access error occurssetBigDecimal(java.lang.String, java.math.BigDecimal)
public byte[] getBytes(int parameterIndex)
throws SQLException
BINARY or
VARBINARY parameter as an array of byte
values in the Java programming language.
getBytes in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is null.
SQLException - if a database access error occurssetBytes(java.lang.String, byte[])
public Date getDate(int parameterIndex)
throws SQLException
DATE parameter as a
java.sql.Date object.
getDate in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is null.
SQLException - if a database access error occurssetDate(java.lang.String, java.sql.Date)
public Time getTime(int parameterIndex)
throws SQLException
TIME parameter as a
java.sql.Time object.
getTime in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is null.
SQLException - if a database access error occurssetTime(java.lang.String, java.sql.Time)
public Timestamp getTimestamp(int parameterIndex)
throws SQLException
TIMESTAMP parameter as a
java.sql.Timestamp object.
getTimestamp in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
NULL, the result
is null.
SQLException - if a database access error occurssetTimestamp(java.lang.String, java.sql.Timestamp)
public Object getObject(int parameterIndex)
throws SQLException
Object
in the Java programming language. If the value is an SQL NULL,
the driver returns a Java null.
This method returns a Java object whose type corresponds to the JDBC
type that was registered for this parameter using the method
registerOutParameter. By registering the target JDBC
type as java.sql.Types.OTHER, this method can be used
to read database-specific abstract data types.
getObject in interface CallableStatementparameterIndex - the first parameter is 1, the second is 2,
and so on
java.lang.Object holding the OUT parameter value
SQLException - if a database access error occursTypes,
setObject(java.lang.String, java.lang.Object, int, int)
public BigDecimal getBigDecimal(int parameterIndex)
throws SQLException
NUMERIC parameter as a
java.math.BigDecimal object with as many digits to the
right of the decimal point as the value contains.
getBigDecimal in interface CallableStatementparameterIndex