Documentation Comments
Use this form to comment on this topic. You can also provide any general observations about the Online Documentation, or request that additional information be added in a future release.
Reality V15.0 ()
: Class RealSQLPreparedStatement (RealSQL-JDBC) (realsqlpreparedstatement.html)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.northgateis.reality.realsql.RealSQLStatement | +--com.northgateis.reality.realsql.RealSQLPreparedStatement
The RealSQLPreparedStatement class is an implementation of the JDBC 2.0 PreparedStatement interface.
When instantiated the object represents a precompiled SQL statement, and can be used to efficiently execute this statement multiple times.
PreparedStatement
,
Connection.prepareStatement(java.lang.String)
,
ResultSet
Method Summary | |
void
|
addBatch()
Currently not supported by the RealSQL-JDBC driver. |
void
|
clearParameters()
Clears the current input parameters. |
void
|
close()
Closes the statement and any associated ResultSet. |
boolean
|
execute()
Executes the stored procedure with its current values. |
java.sql.ResultSet
|
executeQuery()
Executes the stored query with its current values. |
int
|
executeUpdate()
Executes the stored update with its current values. |
protected RealParamData
|
getInputParam(int index)
Retrieves the input parameter specified by the index. |
java.sql.ResultSetMetaData
|
getMetaData()
JDBC 2.0 Gets the number, types and properties of a ResultSet's columns. |
protected int
|
getParamCount()
Retrieves the total number of parameters used by this stored procedure. |
protected void
|
sendParams()
Forwards the values of all registered INPUT parameters to the Reality server, this must be called prior to executing the stored procedure. |
void
|
setArray(int index,
java.sql.Array sqlarray)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setAsciiStream(int index,
java.io.InputStream is,
int len)
Sets the parameter to the data in the specified stream. |
void
|
setBigDecimal(int index,
java.math.BigDecimal bd)
Sets the specified parameter to a BigDecimal value. |
void
|
setBinaryStream(int index,
java.io.InputStream is,
int len)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setBlob(int index,
java.sql.Blob b)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setBoolean(int index,
boolean b)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setByte(int index,
byte b)
Sets the specified parameter to the specified byte value. |
void
|
setBytes(int index,
byte[] barray)
Sets the specified parameter to the specified byte value. |
void
|
setCharacterStream(int index,
java.io.Reader in,
int len)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setClob(int index,
java.sql.Clob c)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setDate(int index,
java.sql.Date d)
Sets the designated parameter to a java.sql.Date value. |
void
|
setDate(int index,
java.sql.Date d,
java.util.Calendar cal)
JDBC 2.0 Sets the designated parameter to a java.sql.Date value, using the given Calendar object. |
void
|
setDouble(int index,
double d)
Sets the specified parameter to a double value. |
void
|
setFloat(int index,
float f)
Sets the specified parameter to a float value. |
void
|
setInt(int index,
int i)
Sets the specified parameter to an int value. |
void
|
setLong(int index,
long l)
Sets the specified parameter to a long value. |
void
|
setNull(int index,
int type)
Sets the specified parameter to a null value. |
void
|
setNull(int index,
int type,
java.lang.String tname)
JDBC 2.0 Sets the specified parameter to a null value. |
void
|
setObject(int index,
java.lang.Object obj)
Sets the specified parameter to a Java object value using the standard mapping from Java Object types to SQL types. |
void
|
setObject(int index,
java.lang.Object obj,
int targetSqlType)
Sets the specified parameter to a Java object value according to the SQL type specified. |
void
|
setObject(int index,
java.lang.Object obj,
int targetSqlType,
int scale)
Sets the specified parameter to a Java object value according to the SQL type specified. |
void
|
setRef(int index,
java.sql.Ref r)
Currently not supported by the RealSQL-JDBC driver. |
void
|
setShort(int index,
short s)
Sets the specified parameter to a short value. |
void
|
setString(int index,
java.lang.String str)
Sets the specified parameter to a String value. |
void
|
setTime(int index,
java.sql.Time t)
Sets the specified parameter to a Time value. |
void
|
setTime(int index,
java.sql.Time t,
java.util.Calendar cal)
Sets the specified parameter to a Time value. |
void
|
setTimestamp(int index,
java.sql.Timestamp t)
Sets the specified parameter to a Timestamp value. |
void
|
setTimestamp(int index,
java.sql.Timestamp t,
java.util.Calendar cal)
Sets the specified parameter to a Timestamp value. |
void
|
setUnicodeStream(int index,
java.io.InputStream is,
int len)
Deprecated. use setCharacterStream() |
protected void
|
validateIndex(int index)
Verifies that the specified index is valid for this stored procedure. |
Methods inherited from class com.northgateis.reality.realsql.RealSQLStatement |
addBatch,
addResultSet,
cancel,
clearBatch,
clearWarnings,
completeLoad,
execute,
executeBatch,
executeCatalogQuery,
executeCommon,
executeQuery,
executeQueryCommon,
executeStmt,
executeUpdate,
executeUpdateCommon,
getConnection,
getFetchDirection,
getFetchSize,
getMaxFieldSize,
getMaxRows,
getMoreResults,
getQueryTimeout,
getResultSet,
getResultSetConcurrency,
getResultSetType,
getUpdateCount,
getWarnings,
isCatalogQuery,
methodNotSupported,
prepareStmt,
reset,
setCursorName,
setEscapeProcessing,
setFetchDirection,
setFetchSize,
setMaxFieldSize,
setMaxRows,
setQueryTimeout |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Method Detail |
public void addBatch() throws java.sql.SQLException
Adds the current parameter values to the batch list and then clears the parameters for the next set of parameters.
public void clearParameters() throws java.sql.SQLException
public void close() throws java.sql.SQLException
public boolean execute() throws java.sql.SQLException
public java.sql.ResultSet executeQuery() throws java.sql.SQLException
public int executeUpdate() throws java.sql.SQLException
public java.sql.ResultSetMetaData getMetaData() throws java.sql.SQLException
public void setArray(int index, java.sql.Array sqlarray) throws java.sql.SQLException
JDBC 2.0 Sets an Array parameter.
index
- the parameter to be set.sqlarray
- object representing an SQL array.public void setAsciiStream(int index, java.io.InputStream is, int len) throws java.sql.SQLException
index
- the parameter to setis
- the input stream containing the datalen
- the number of bytes in the streampublic void setBigDecimal(int index, java.math.BigDecimal bd) throws java.sql.SQLException
index
- the parameter to be setbd
- the BigDecimal valuepublic void setBinaryStream(int index, java.io.InputStream is, int len) throws java.sql.SQLException
Sets the parameter to the data in the specified stream.
index
- the parameter to setis
- the input stream containing the datalen
- the number of bytes in the streampublic void setBlob(int index, java.sql.Blob b) throws java.sql.SQLException
Sets the specified parameter to a Blob value.
index
- the parameter to be setb
- the Blob valuepublic void setBoolean(int index, boolean b) throws java.sql.SQLException
Sets the specified parameter to a boolean value. This will set the column to the integer value 1 for true or 0 for false.
index
- the parameter to set.b
- the value to set.public void setByte(int index, byte b) throws java.sql.SQLException
index
- the parameter to be setb
- the byte value.public void setBytes(int index, byte[] barray) throws java.sql.SQLException
index
- the parameter to be set.barray
- the byte array value.public void setCharacterStream(int index, java.io.Reader in, int len) throws java.sql.SQLException
JDBC 2.0 Sets the designated parameter to the given Reader object, which is the given number of characters long.
index
- the parameter to set.in
- the stream containing the data.len
- the number of bytes in the stream.public void setClob(int index, java.sql.Clob c) throws java.sql.SQLException
Sets the specified parameter to a Clob value.
index
- the parameter to be setc
- the Clob valuepublic void setDate(int index, java.sql.Date d) throws java.sql.SQLException
index
- the parameter to be set.d
- the Date value to set.public void setDate(int index, java.sql.Date d, java.util.Calendar cal) throws java.sql.SQLException
index
- the parameter to be set.d
- the Date value to set.cal
- the Calendar to use.public void setDouble(int index, double d) throws java.sql.SQLException
index
- the parameter to be setd
- the value to set.public void setFloat(int index, float f) throws java.sql.SQLException
index
- the parameter to be set.f
- the value to set.public void setInt(int index, int i) throws java.sql.SQLException
index
- the parameter to be set.i
- the value to set.public void setLong(int index, long l) throws java.sql.SQLException
index
- the parameter to be set.l
- the value to set.public void setNull(int index, int type) throws java.sql.SQLException
index
- the parameter to be set.type
- the SQL type of the value to be set.public void setNull(int index, int type, java.lang.String tname) throws java.sql.SQLException
index
- the parameter to be set.type
- the SQL type of the value to be set - not used.tname
- the name of the UDT - not used.public void setObject(int index, java.lang.Object obj) throws java.sql.SQLException
index
- the parameter to be set.obj
- the object to be set.public void setObject(int index, java.lang.Object obj, int targetSqlType) throws java.sql.SQLException
index
- the parameter to be set.ob
- the object to be set.type
- the target SQL type.public void setObject(int index, java.lang.Object obj, int targetSqlType, int scale) throws java.sql.SQLException
index
- the parameter to be setobj
- the object to be set.type
- the target SQL type.scale
- this is ignored.public void setRef(int index, java.sql.Ref r) throws java.sql.SQLException
Sets the specified parameter to a Ref value.
index
- the parameter to be set.r
- the Ref value.public void setShort(int index, short s) throws java.sql.SQLException
index
- the parameter to be set.s
- the value to set.public void setString(int index, java.lang.String str) throws java.sql.SQLException
index
- the parameter to be set.str
- the value to set.public void setTime(int index, java.sql.Time t) throws java.sql.SQLException
index
- the parameter to be set.t
- the value to set.public void setTime(int index, java.sql.Time t, java.util.Calendar cal) throws java.sql.SQLException
index
- the parameter to be set.t
- the value to set.cal
- the Calendar to use.public void setTimestamp(int index, java.sql.Timestamp t) throws java.sql.SQLException
index
- the parameter to be set.t
- the value to set.public void setTimestamp(int index, java.sql.Timestamp t, java.util.Calendar cal) throws java.sql.SQLException
index
- the parameter to be set.t
- the value to set.cal
- the Calendar to use.public void setUnicodeStream(int index, java.io.InputStream is, int len) throws java.sql.SQLException
Sets the specified parameter to the data contained in the specified unicode stream.
index
- the parameter being setis
- the input stream with the data.len
- the number of bytes to be read.protected void validateIndex(int index) throws java.sql.SQLException
index
- the parameter number to be testedprotected void sendParams() throws java.sql.SQLException
protected RealParamData getInputParam(int index)
protected int getParamCount()
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |