What is execute(), executeUpdate() and executeQuery()
methods?
Answer Posted / trio
boolean execute()
Executes the SQL statement in this PreparedStatement
object, which may be any kind of SQL statement.
ResultSet executeQuery()
Executes the SQL query in this PreparedStatement object and
returns the ResultSet object generated by the query.
int executeUpdate()
Executes the SQL statement in this PreparedStatement
object, which must be an SQL INSERT, UPDATE or DELETE
statement; or an SQL statement that returns nothing, such
as a DDL statement.
| Is This Answer Correct ? | 39 Yes | 4 No |
Post New Answer View All Answers
How to know howmuch data is truncated?
Explain the JDBC Architecture?
What is the difference between client and server database cursors?
What is in terms of jdbc a datasource?
What is JDBC Connection? Explain steps to get Database connection in a simple java program.
How can I write to the log used by DriverManager and JDBC drivers?
What does it mean to "materialize" data?
What is jdbc and its types?
What is the use of jdbc api?
How can you make the connection using jdbc?
How do I insert an image file (or other raw data) into a database?
What are the different classes through which JDBC represents statements?
Describe the steps needed to execute a sql query using jdbc.
What are jdbc and its components?
What is connection commit?