PreparedStatement interface methods |
Method return value type |
Method |
|
|
void |
clearParameters()
Clears the current parameter values immediately. |
|
|
boolean |
execute()
Executes any kind of SQL statement. |
|
|
ResultSet |
executeQuery()
Executes the SQL query in this PreparedStatement object and returns the result set generated by the query. |
|
|
int |
executeUpdate()
Executes the SQL INSERT, UPDATE or DELETE statement in this PreparedStatement object. |
|
|
void |
setBigDecimal (int parameterIndex, BigDecimal x)
Sets the designated parameter to a java.lang.BigDecimal value. |
|
|
void |
setBinaryStream(int parameterIndex, InputStream x, int length) |
|
|
void |
setBoolean (int parameterIndex, boolean x)
Sets the designated parameter to a Java boolean value. JDBC driver converts this to an SQL SMALLINT value when it sends it to the database. |
|
|
void |
setBlob(int i, Blob x) JDBC 2.0
Sets a BLOB parameter. |
|
|
void |
setDate(int parameterIndex, Date x)
Sets the designated parameter to a java.sql.Date value. |
|
|
void |
setDouble(int parameterIndex, double x)
Sets the designated parameter to a Java double value. JDBC driver converts this to an SQL DECIMAL value when it sends it to the database. |
|
|
void |
setFloat(int parameterIndex, float x)
Sets the designated parameter to a Java float value. When a BigDecimal is converted to float, if the BigDecimal is too large to represent as a float, it will be converted to FLOAT.NEGATIVE_INFINITY or FLOAT.POSITIVE_INFINITY as appropriate. |
|
|
void |
setInt (int parameterIndex, int x)
Sets the designated parameter to a Java int value. |
|
|
void |
setLong(int parameterIndex, long x)
Sets the designated parameter to a Java long value. |
|
|
void |
setNull (int parameterIndex, int sqlType)
Sets the designated parameter to SQL NULL. |
|
|
void |
setObject(int parameterIndex, Object x, int targetSqlType)
Sets the value of the designated parameter with the given object. |
|
|
void |
setShort (int parameterIndex, short x)
Sets the designated parameter to a Java short value. |
|
|
void |
setString (int parameterIndex, String x)
Sets the designated parameter to a Java String value. |
|
|
void |
setTime (int parameterIndex, Time x)
Sets the designated parameter to a java.sql.Time value. |
|
|
void |
setTimestamp (int parameterIndex, Timestamp x)
Sets the designated parameter to a java.sql.Timestamp value |
|
|
void |
setTimestamp (int parameterIndex, Timestamp x)
Sets the designated parameter to a java.sql.Timestamp value |