sql - Informix: procedure with output parameters? -


i searched lot, couldn't find anything.. want ask if there's way create , call procedure (informix) out parameters. know how return 1 or more values (for procedures , functions), not want. strange, if informix not allow output parameters..

thanks in advance!

edit: yes, saw it's possible, still can't execute such procedure. example:

  create procedure mytest(batch int,out p_out int)     define inc integer;     let inc = 1;     let p_out = 5;     end procedure;   

and receive is:

the routine mytest can not resolved

and happens on executing functions output parameters..

why need 'out' parameters? informix procedures can return multiple values single call (or, in case, single value):

  create procedure mytest(batch int) returning int p_out;       define inc integer;       define p_out integer;       let inc = 1;       let p_out = batch + inc;       return p_out;   end procedure; 

there limited number of places can use out parameter. 1 in query - there name slv (statement local variable) turns in error messages. believe there's way out parameters via java (jdbc) too. afaik, other apis not allow it.

code written informix assumes won't need output parameters. code migrated informix other (impoverished?) systems not provide multiple output values single procedure need rethought work sensibly informix.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -