DBAsupport.com Forums - Powered by vBulletin
Results 1 to 1 of 1

Thread: PLS-00320: the declaration of the type of this expression is incomplete or malformed

  1. #1
    Join Date
    Feb 2006
    Posts
    3

    PLS-00320: the declaration of the type of this expression is incomplete or malformed

    Hello All

    Working with a procedure that returns cursor. Here is sample code
    CREATE OR REPLACE PACKAGE TEST AS
    TYPE OUTCURSOR IS REF CURSOR;
    PROCEDURE GETLIST (
    P_PARAMOUTPUT OUT OUTCURSOR,
    P_PARAMINPUT IN INTEGER);
    END TEST;
    /
    CREATE OR REPLACE PACKAGE BODY TEST AS
    PROCEDURE GETLIST (
    P_PARAMOUTPUT OUT OUTCURSOR,
    P_PARAMINPUT IN INTEGER) IS
    MYCURSOR OUTCURSOR;
    BEGIN
    DBMS_OUTPUT.PUT_LINE ('TEST' || P_PARAMINPUT);

    OPEN MYCURSOR
    FOR 'select * from eventtypes';
    END GETLIST;
    END TEST;

    When i execute this procedure i am getting error of
    "PLS-00320: the declaration of the type of this expression is incomplete or malformed"

    When i see code through TOAD i see new variable added of ROWTYPE thats causing the problem

    CODE FROM TOAD
    ================
    DECLARE
    P_PARAMOUTPUT TEST.OUTCURSOR;
    P_PARAMOUTPUT_row P_PARAMOUTPUT%ROWTYPE;
    P_PARAMINPUT NUMBER;
    BEGIN
    P_PARAMINPUT := 9;
    DAE_ADMIN.TEST.GETLIST ( P_PARAMOUTPUT, P_PARAMINPUT );
    COMMIT;
    END;

    if i remove " P_PARAMOUTPUT_row P_PARAMOUTPUT%ROWTYPE;" this line its not throwing any error same time i am not getting results.

    Any hints to solve this issue.

    -Raj
    Last edited by rklakamana; 02-22-2006 at 10:58 AM.

Posting Permissions

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


Click Here to Expand Forum to Full Width