What is actual difference between statement,prepared
statement and callable statement and when we have to use it?
pls post a answer with code and clear explanation. thanks

Answer Posted / sudha

Prepared statement is precompiled statement it is used when
we want one query to be executed n no. of times.
whereas callablestatement is used to call stored procedures

Is This Answer Correct ?    41 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can inner class have constructor?

732


What is ternary operator? Give an example.

788


Can we declare a constructor as final?

886


How many types of parsers are there?

773


Can we call a non-static method from inside a static method?

769


Can we modify the throws clause of the superclass method while overriding it in the subclass?

758


how a programmer confirms that the data submitted has been succesfully inserted into the database(either oracle or my sql).. How a programmer confirm if there is any problem with the program he wrote for insertion... ANS:--- >executeupdate method is having boolean return type, if anything goes wrong in data insertion or data updation, it would return false. otherwise, if it successfully inserts data into the database, it would return true NOW HOW TO I CHECK IN MY DURING EXECUTION WHETHER IT RETURNS TRUE OR FALSE... WELL IT WILL DISPLAY ANY MESSAGE OR NOT

2086


How do you convert boolean to boolean?

770


What is the static block?

785


Explain about assignment statement?

786


Is java a pure object oriented language?

721


What is the reason behind using constructors and destructors?

781


What is the differences between heap and stack memory in java? Explain

724


Explain about object oriented programming and its features?

789


Difference between stack and queue?

785