Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2002
    Posts
    162

    Unanswered: calling one stored proc from another stored proc using bind variable??

    Hi guys,

    I'm tryin to call -this stored proc:

    CREATE OR REPLACE PROCEDURE REACTIVATE_EMP_ASSESSMENT(p_empstr IN varchar, p_retriever_emplid IN varchar, p_activation IN varchar, p_out OUT VARCHAR2)

    from within this stored proc:

    CREATE OR REPLACE PROCEDURE CLOSE_ASSESSMENT(p_assidstr IN varchar, p_closed_reason IN varchar,p_closer_emplid IN varchar)

    I have a number of variables defined in the second stored proc that I'm passing in as the parameters for the first stored proc. but I'm having issues with passing in the variable for the out parameter (p_out)

    how do I do this??

    In SQL plus all you have to do is type:

    VARIABLE status NUMBER

    and then call the proc like so:

    execute rectivate_emp_assessment('54389','502507','Y',
    :status);


    and it works perfectly. So basically my question is how do I pass in a bind variable in PL/SQL to another stored proc call??


    Thanks in Advance.

    'Wale

  2. #2
    Join Date
    Sep 2002
    Location
    UK
    Posts
    5,171
    Provided Answers: 1

    Re: calling one stored proc from another stored proc using bind variable??

    What sort of issues?
    PHP Code:
    SQLcreate or replace procedure a i in numbero out number is
      2  begin
      3    o 
    := i*2;
      
    4  end;
    SQL> /

    Procedure created.

    SQLcreate or replace procedure b i in number is
      2    v number
    ;
      
    3  begin
      4    a 
    (iv);
      
    5    dbms_output.put_line(v);
      
    6  end;
    SQL> /

    Procedure created.

    SQLexec b(9)
    18

    PL
    /SQL procedure successfully completed

Posting Permissions

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