org.firebirdsql.jdbc
Class FBPreparedStatement

java.lang.Object
  extended by org.firebirdsql.jdbc.AbstractStatement
      extended by org.firebirdsql.jdbc.AbstractPreparedStatement
          extended by org.firebirdsql.jdbc.FBPreparedStatement
All Implemented Interfaces:
PreparedStatement, Statement, Wrapper, FirebirdPreparedStatement, FirebirdStatement, Synchronizable

public class FBPreparedStatement
extends AbstractPreparedStatement

Author:
Roman Rokytskyy

Field Summary
 
Fields inherited from class org.firebirdsql.jdbc.AbstractPreparedStatement
isParamSet
 
Fields inherited from class org.firebirdsql.jdbc.AbstractStatement
completed, fetchSize, firstWarning, fixedStmt, gdsHelper, hasMoreResults, isResultSet, maxRows, statementListener
 
Fields inherited from interface org.firebirdsql.jdbc.FirebirdPreparedStatement
TYPE_COMMIT, TYPE_DDL, TYPE_DELETE, TYPE_EXEC_PROCEDURE, TYPE_GET_SEGMENT, TYPE_INSERT, TYPE_PUT_SEGMENT, TYPE_ROLLBACK, TYPE_SELECT, TYPE_SELECT_FOR_UPDATE, TYPE_SET_GENERATOR, TYPE_START_TRANS, TYPE_UPDATE
 
Fields inherited from interface org.firebirdsql.jdbc.FirebirdStatement
CLOSE_ALL_RESULTS, CLOSE_CURRENT_RESULT, KEEP_CURRENT_RESULT
 
Fields inherited from interface java.sql.Statement
EXECUTE_FAILED, NO_GENERATED_KEYS, RETURN_GENERATED_KEYS, SUCCESS_NO_INFO
 
Constructor Summary
FBPreparedStatement(GDSHelper gdsHelper, String sql, int rsType, int rsConcurrency, int rsHoldability, FBObjectListener.StatementListener statementListener, FBObjectListener.BlobListener blobListener, boolean metaDataQuery, boolean standaloneStatement)
           
 
Method Summary
 boolean execute(String param1, int param2)
          jdbc 3
 boolean execute(String param1, int[] param2)
          jdbc 3
 boolean execute(String param1, String[] param2)
          jdbc 3
 int executeUpdate(String param1, int param2)
          jdbc 3
 int executeUpdate(String param1, int[] param2)
          jdbc 3
 int executeUpdate(String param1, String[] param2)
          jdbc 3
 ResultSet getGeneratedKeys()
          jdbc 3
 ParameterMetaData getParameterMetaData()
          Retrieves the number, types and properties of this PreparedStatement object's parameters.
 boolean isPoolable()
           
 boolean isWrapperFor(Class arg0)
           
 void setAsciiStream(int parameterIndex, InputStream x)
           
 void setAsciiStream(int parameterIndex, InputStream x, long length)
           
 void setBinaryStream(int parameterIndex, InputStream x)
           
 void setBinaryStream(int parameterIndex, InputStream x, long length)
           
 void setBlob(int parameterIndex, InputStream inputStream)
           
 void setBlob(int parameterIndex, InputStream inputStream, long length)
           
 void setCharacterStream(int parameterIndex, Reader reader)
           
 void setCharacterStream(int parameterIndex, Reader reader, long length)
           
 void setClob(int parameterIndex, Reader reader)
           
 void setClob(int parameterIndex, Reader reader, long length)
           
 void setNCharacterStream(int parameterIndex, Reader value)
           
 void setNCharacterStream(int parameterIndex, Reader value, long length)
           
 void setNClob(int parameterIndex, NClob value)
           
 void setNClob(int parameterIndex, Reader reader)
           
 void setNClob(int parameterIndex, Reader reader, long length)
           
 void setNString(int parameterIndex, String value)
           
 void setPoolable(boolean poolable)
           
 void setRowId(int parameterIndex, RowId x)
           
 void setSQLXML(int parameterIndex, SQLXML xmlObject)
           
 void setURL(int parameterIndex, URL url)
          Sets the designated parameter to the given java.net.URL value.
 Object unwrap(Class arg0)
           
 
Methods inherited from class org.firebirdsql.jdbc.AbstractPreparedStatement
addBatch, clearBatch, clearParameters, completeStatement, execute, executeBatch, executeQuery, executeUpdate, getExecutionPlan, getField, getMetaData, getStatementType, getXsqlvar, internalExecute, notifyStatementCompleted, prepareFixedStatement, setArray, setAsciiStream, setBigDecimal, setBinaryStream, setBlob, setBoolean, setByte, setBytes, setCharacterStream, setClob, setDate, setDate, setDouble, setFloat, setInt, setLong, setNull, setNull, setObject, setObject, setObject, setRef, setShort, setString, setStringForced, setTime, setTime, setTimestamp, setTimestamp, setUnicodeStream
 
Methods inherited from class org.firebirdsql.jdbc.AbstractStatement
addBatch, addWarning, cancel, clearWarnings, close, execute, executeQuery, executeUpdate, finalize, forgetResultSet, getConnection, getCurrentResultSet, getDeletedRowsCount, getFetchDirection, getFetchSize, getInsertedRowsCount, getLastExecutionPlan, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getSynchronizationObject, getUpdateCount, getUpdatedRowsCount, getWarnings, hasOpenResultSet, internalExecute, isClosed, isExecuteProcedureStatement, isValid, nativeSQL, notifyStatementCompleted, notifyStatementStarted, notifyStatementStarted, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setMaxFieldSize, setMaxRows, setQueryTimeout, toArray
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.firebirdsql.jdbc.FirebirdStatement
getCurrentResultSet, getDeletedRowsCount, getInsertedRowsCount, getLastExecutionPlan, getUpdatedRowsCount, hasOpenResultSet, isValid
 
Methods inherited from interface java.sql.Statement
addBatch, cancel, clearWarnings, close, execute, executeQuery, executeUpdate, getConnection, getFetchDirection, getFetchSize, getMaxFieldSize, getMaxRows, getMoreResults, getMoreResults, getQueryTimeout, getResultSet, getResultSetConcurrency, getResultSetHoldability, getResultSetType, getUpdateCount, getWarnings, isClosed, setCursorName, setEscapeProcessing, setFetchDirection, setFetchSize, setMaxFieldSize, setMaxRows, setQueryTimeout
 

Constructor Detail

FBPreparedStatement

public FBPreparedStatement(GDSHelper gdsHelper,
                           String sql,
                           int rsType,
                           int rsConcurrency,
                           int rsHoldability,
                           FBObjectListener.StatementListener statementListener,
                           FBObjectListener.BlobListener blobListener,
                           boolean metaDataQuery,
                           boolean standaloneStatement)
                    throws SQLException
Throws:
SQLException
Method Detail

setURL

public void setURL(int parameterIndex,
                   URL url)
            throws SQLException
Sets the designated parameter to the given java.net.URL value. The driver converts this to an SQL DATALINK value when it sends it to the database.

Parameters:
parameterIndex - the first parameter is 1, the second is 2, ...
url - the java.net.URL object to be set
Throws:
SQLException - if a database access error occurs
Since:
1.4

getParameterMetaData

public ParameterMetaData getParameterMetaData()
                                       throws SQLException
Retrieves the number, types and properties of this PreparedStatement object's parameters.

Returns:
a ParameterMetaData object that contains information about the number, types and properties of this PreparedStatement object's parameters
Throws:
SQLException - if a database access error occurs
Since:
1.4
See Also:
ParameterMetaData

getGeneratedKeys

public ResultSet getGeneratedKeys()
                           throws SQLException
jdbc 3

Returns:
Throws:
SQLException -

executeUpdate

public int executeUpdate(String param1,
                         int param2)
                  throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

executeUpdate

public int executeUpdate(String param1,
                         int[] param2)
                  throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

executeUpdate

public int executeUpdate(String param1,
                         String[] param2)
                  throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

execute

public boolean execute(String param1,
                       int param2)
                throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

execute

public boolean execute(String param1,
                       int[] param2)
                throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

execute

public boolean execute(String param1,
                       String[] param2)
                throws SQLException
jdbc 3

Parameters:
param1 -
param2 -
Returns:
Throws:
SQLException -

setAsciiStream

public void setAsciiStream(int parameterIndex,
                           InputStream x,
                           long length)
                    throws SQLException
Throws:
SQLException

setAsciiStream

public void setAsciiStream(int parameterIndex,
                           InputStream x)
                    throws SQLException
Throws:
SQLException

setBinaryStream

public void setBinaryStream(int parameterIndex,
                            InputStream x,
                            long length)
                     throws SQLException
Throws:
SQLException

setBinaryStream

public void setBinaryStream(int parameterIndex,
                            InputStream x)
                     throws SQLException
Throws:
SQLException

setBlob

public void setBlob(int parameterIndex,
                    InputStream inputStream,
                    long length)
             throws SQLException
Throws:
SQLException

setBlob

public void setBlob(int parameterIndex,
                    InputStream inputStream)
             throws SQLException
Throws:
SQLException

setCharacterStream

public void setCharacterStream(int parameterIndex,
                               Reader reader,
                               long length)
                        throws SQLException
Throws:
SQLException

setCharacterStream

public void setCharacterStream(int parameterIndex,
                               Reader reader)
                        throws SQLException
Throws:
SQLException

setClob

public void setClob(int parameterIndex,
                    Reader reader,
                    long length)
             throws SQLException
Throws:
SQLException

setClob

public void setClob(int parameterIndex,
                    Reader reader)
             throws SQLException
Throws:
SQLException

setNCharacterStream

public void setNCharacterStream(int parameterIndex,
                                Reader value,
                                long length)
                         throws SQLException
Throws:
SQLException

setNCharacterStream

public void setNCharacterStream(int parameterIndex,
                                Reader value)
                         throws SQLException
Throws:
SQLException

setNClob

public void setNClob(int parameterIndex,
                     NClob value)
              throws SQLException
Throws:
SQLException

setNClob

public void setNClob(int parameterIndex,
                     Reader reader,
                     long length)
              throws SQLException
Throws:
SQLException

setNClob

public void setNClob(int parameterIndex,
                     Reader reader)
              throws SQLException
Throws:
SQLException

setNString

public void setNString(int parameterIndex,
                       String value)
                throws SQLException
Throws:
SQLException

setRowId

public void setRowId(int parameterIndex,
                     RowId x)
              throws SQLException
Throws:
SQLException

setSQLXML

public void setSQLXML(int parameterIndex,
                      SQLXML xmlObject)
               throws SQLException
Throws:
SQLException

isPoolable

public boolean isPoolable()
                   throws SQLException
Throws:
SQLException

setPoolable

public void setPoolable(boolean poolable)
                 throws SQLException
Throws:
SQLException

isWrapperFor

public boolean isWrapperFor(Class arg0)
                     throws SQLException
Throws:
SQLException

unwrap

public Object unwrap(Class arg0)
              throws SQLException
Throws:
SQLException


Copyright © 2001-2010. All Rights Reserved.