Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2006

    Unanswered: Problem when calling a stored procedure from within another

    Hi all,
    I have a stored procedure that loops through a cursor and then needs to call another procedure with a value from the cursor as an input.

    Here is the section of my main procedure that deals with it:

    Elsif v_transType = 'A' then
    -- If the transtype is an adjustment loop through each adjustment, 
    -- passing the applyto transno into p_glAdjust procedure to write reversals to GL CONTROL
      OPEN c_bill;
                        FETCH c_bill INTO r_bill;
                        EXIT  WHEN c_bill%NOTFOUND;
        call p_glAdjust(r_bill.applyto);             
      END LOOP;
      CLOSE c_bill;
    when I compile the entire main Stored Procedure (p_glAdjust is already compiled) it returns the error:
    Error(481,10): PLS-00103: Encountered the symbol "P_GLADJUST" when expecting one of the following:     
    := . ( @ % ; The symbol ":=" was substituted for "P_GLADJUST" to continue.
    can anybody suggest what I am doign wrong.
    Is it not possible to call another procedure in this manner?

    Thanks in advance,
    Last edited by matpj; 09-08-09 at 03:54.

  2. #2
    Join Date
    Jan 2004
    Croatia, Europe
    Provided Answers: 4
    It is possible, but not with the "call" word. Where did you find that PL/SQL procedures are called by using "call"? Just name it!

Posting Permissions

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