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

Thread: cursor variables

  1. #1
    Join Date
    May 2001
    Posts
    5

    Question

    I am trying to start to use cursor variables I believe i have declared properly but get the following error on this code:
    I will be trying to pass the cursor with a table name


    CREATE OR REPLACE PACKAGE archive_database AS

    CURSOR get_tables(p_owner VARCHAR2) RETURN dba_tables%ROWTYPE;
    CURSOR get_columns(p_table VARCHAR2) RETURN dba_tab_columns%ROWTYPE;
    CURSOR get_tab_data IS REF CURSOR;
    PROCEDURE select_data (v_owner VARCHAR2);
    PROCEDURE get_data(alldata IN OUT get_tab_data, p_table VARCHAR2);

    END archive_database;
    /


    LINE/COL ERROR
    -------- -----------------------------------------------------------------
    5/25 PLS-00103: Encountered the symbol "REF" when expecting one of the
    following:
    ( select

    cheers
    suggs
    Suggs

  2. #2
    Join Date
    Apr 2001
    Posts
    51

    The delaration for refcursor should be as follows:

    type get_tab_data IS REF CURSOR;

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