Jdbc operation database process

Jdbc operation database process The
first step: Class.forName () loads the database connection driver; the
second step: DriverManager.getConnection () to obtain the data connection object; the
third step: according to SQL to obtain the sql session object, there are 2 ways Statement, PreparedStatement The
fourth step: execute the SQL processing result set, if the parameter value is set before executing SQL, set the parameter value setXXX (); the
fifth step: close the result set, close the session, and close the connection. 

143 original articles published · Like 112 · Visitors 8416

Guess you like

Origin blog.csdn.net/weixin_45151795/article/details/105697355