The life cycle of a servlet consists of the following phases:
- DriverManager: Manages a list of database drivers. Matches connection requests from the java application with the proper database driver using communication subprotocol. The first driver that recognizes a certain subprotocol under JDBC will be used to establish a database Connection.
- Driver: The database communications link, handling all communication with the database. Normally, once the driver is loaded, the developer need not call it explicitly.
- Connection : Interface with all methods for contacting a database.The connection object represents communication context, i.e., all communication with database is through connection object only.
- Statement : Encapsulates an SQL statement which is passed to the database to be parsed, compiled, planned and executed.
- ResultSet: The ResultSet represents set of rows retrieved due to query execution.
No comments:
Post a Comment