What is the difference between ExecuteUpdate and
ExecuteQuery?

Answer Posted / anji

executeUpdate() - is used to update or modify the table, it
will returns howmany rows added/updated in the table.

executeQuery() - is used to retrieve the data from the
table. only for "select" query, this will return a
Resultset metadata

Is This Answer Correct ?    42 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is ServletConfig object?

582


How can you use a servlet to generate a plain text instead of html?

561


What is the major difference between servlet and applet?

523


how the HTML data stored in web server?

1939


What are the benefits of using servlet over cgi?

547






Servlet is pure java object or not?

695


What is a deployment descriptor?

572


Can we use the constructor, instead of init(), to initialize servlet?

561


Differentiate between get and post?

662


What is the use of httpservletrequestwrapper?

567


Why do we have servlet filters?

579


How do you configure a centralized error handler in servlets?

511


How is an application exception handling is done using a servlet?

513


How do you design microservices?

595


Explain mvc pattern.

565