Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2004
    Posts
    15

    Unanswered: PLS-00382: expression is of wrong type

    Hi,


    Code:
    TYPE test_type IS REF CURSOR RETURN TestTable%ROWTYPE;
    cur_test  test_type;
    OPEN cur_test FOR SELECT col1, col2, col3  FROM TestTable;
    In a procedure i tried to open a ref cursor, and ended up with this error..

    PLS-00382: expression is of wrong type

    the problem here is i have not used all the columns of TestTable in my cursor declaration as defined in the TYPE definition of test_type. My test table has some more columns (say col4 and col5), this is my guess,..

    i would like to know, does the above error (PLS-00382) occurs due to any other reasons failing my guess,...

    thanks,
    Sn.,

  2. #2
    Join Date
    Jan 2004
    Location
    Croatia, Europe
    Posts
    4,094
    Provided Answers: 4
    Well, you could have tried it yourself, couldn't you?

    Either make ref cursor weak (instead of strong) (such as "type test_type is ref cursor;") or select all columns from testtable.

Posting Permissions

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