O'Reilly logo

Database Programming with JDBC & Java, Second Edition by George Reese

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

PreparedStatement

Synopsis

Interface Name: java.sql.PreparedStatement

Superclass: java.sql.Statement

Immediate Subclasses: java.sql.CallableStatement

Interfaces Implemented: None

Availability: JDK 1.1

Description

This class represents a precompiled SQL statement.

Class Summary

public interface PreparedStatement extends Statement {
    void addBatch( ) throws SQLException;
    void clearParameters( ) throws SQLException;
    boolean execute( ) throws SQLException;
    ResultSet executeQuery( ) throws SQLException;
    int executeUpdate( ) throws SQLException;
    ResultSetMetaData getMetaData( ) throws SQLException;
                     void setArray(int index, Array arr) 
        throws SQLException; 
    void setAsciiStream(int index, InputStream is, 
        int length) throws SQLException;
    void setBigDecimal(int index, BigDecimal d) 
        throws SQLException;
    void setBinaryStream(int index, InputStream is, 
        int length) throws SQLException;
    void setBlob(int index, Blob b) throws SQLException;
    void setBoolean(int index, boolean b)
        throws SQLException;
    void setByte(int index, byte b) throws SQLException;
    void setBytes(int index, byte[] bts)
        throws SQLException;
    void setCharacterStream(int index, Reader rdr, 
        int length) throws SQLException;
    void setClob(int index, Clob c) throws SQLException;
    void setDate(int index, Date d) throws SQLException;
    void setDate(int index, Date d, Calendar cal)
        throws SQLException; void setDouble(int index, double x) throws SQLException; void setFloat(int index, float f) throws SQLException; void setInt(int index, int x) throws ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required