Documentation

Trace:

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
jvx:server:db:func_proc [2018/02/02 11:18]
admin
jvx:server:db:func_proc [2020/06/29 13:06] (current)
cduncan Edited for English grammar (capitalization, punctuation, correct verb conjugation)
Line 1: Line 1:
 ~~NOTRANS~~ ~~NOTRANS~~
-~~Title: Functions and Procedures ​with IN and OUT parameters~~+~~Title: Functions and Procedures ​With IN and OUT Parameters~~
  
-If you use database procedures and/or functions in your application,​ wouldn'​t it be great to call them with one simple callNormally a function or procedure call is very complexbecause you have to define a CallableStatement,​ set the output parameters, execute the statement and read the result. And don't forget that the parameter index starts with 1 instead of 0!+If you use database procedures and/or functions in your application,​ wouldn'​t it be great to call them with one simple callNormallya function or procedure call is very complex because you have to define a CallableStatement,​ set the output parameters, execute the statementand read the result. And don't forget that the parameter index starts with 1 instead of 0!
  
-Suppose we have a function (e.g. Oracle):+Suppose we have a function (e.g.Oracle):
  
 <file plsql> <file plsql>
Line 20: Line 20:
 </​file>​ </​file>​
  
-The function is simplebut uses one in/out and one out parameter. A standard JDBC call looks like:+The function is simple but uses one in/out and one out parameter. A standard JDBC call looks like:
  
 <file java> <file java>
Line 68: Line 68:
 </​file>​ </​file>​
  
-The ''​executeFunction''​ method supports standard Java Objects ​and our special Param objects, as used in the previous example.+The ''​executeFunction''​ method supports standard Java objects ​and our special Param objects, as used in the previous example.
  
 If you want to call a database procedure instead of a function, use the same classes and call ''​executeProcedure''​. If you want to call a database procedure instead of a function, use the same classes and call ''​executeProcedure''​.
  
This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information