Home » Developer & Programmer » JDeveloper, Java & XML » what is the difference between execute() and executeUpdate() methods in JDBC
what is the difference between execute() and executeUpdate() methods in JDBC [message #92398] Wed, 30 June 2004 06:35 Go to next message
Jyothi
Messages: 12
Registered: May 2002
Junior Member
-

Hi,

Can someone explain me the difference between execute() and executeUpdate() methods in JDBC,I understand that executeUpdate() is to execute the DML stmts like Insert/Update/Delete,but the same statements can also be executed by execute() method. Which method is best for performance issues?

Thanks

Jyothi.

 

 
-
Re: what is the difference between execute() and executeUpdate() methods in JDBC [message #92542 is a reply to message #92398] Wed, 08 September 2004 09:38 Go to previous message
Bhagavan Chowdary Adusumi
Messages: 1
Registered: September 2004
Junior Member
execute()::

Executes the SQL statement in the PreparedStatement object, which may be any kind of SQL statement,which returns either true or false means return type is boolean

executeUpdate()::

Executes the SQL statement in the PreparedStatement object, which must be an SQL INSERT, UPDATE or DELETE statement; or an SQL statement that returns nothing, such as a DDL statement.This returns integer which may be number of rows inserted ,updated or deleted.
Previous Topic: UUID Generator
Next Topic: query about learning java
Goto Forum:
  


Current Time: Tue Nov 26 01:10:01 CST 2024