To execute SQL statements against a database, an application uses Statements (java.sql.Statement) and PreparedStatements (java.sql.PreparedStatement), or CallableStatements (java.sql.CallableStatement) for stored procedures.

Because PreparedStatement extends Statement and CallableStatement extends PreparedStatement, this section refers to both as Statements. Statements are obtained from and are associated with a particular Connection.

Related concepts
ResultSets and Cursors
Nested connections