Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2003
    Location
    London
    Posts
    16

    Unanswered: Testing stored procedure with out argument

    Can anyone tell me how to call a stored procedure from the command center or command line. The procedure has 1- IN and 1- OUT argument. I basically want to print the output to screen.

    The documentation ive got doesnt seem to be too clear on this subject.

  2. #2
    Join Date
    Jan 2003
    Posts
    4,292
    Provided Answers: 5
    Assuming your procedure is defined like this:

    create procedure myproc(in var1 int, out var2 int)....

    from the CLP or the Command Center

    call myproc(1,?)

    For the IN parameters, you specify the value you want, for the OUT parameters you supply a question mark (?).

    That is all there is to it.

    Andy

  3. #3
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: Testing stored procedure with out argument

    What platform and version are you on ?

    CALL was introduced in DB2 LUW V7 in one of the early fixpacks .. I don't remember which one ... Does anyone remember ?

    Cheers

    Sathyaram

    Originally posted by blakmk
    Can anyone tell me how to call a stored procedure from the command center or command line. The procedure has 1- IN and 1- OUT argument. I basically want to print the output to screen.

    The documentation ive got doesnt seem to be too clear on this subject.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •