오라클 파라미터 넘기는 부분의 에러 0 2 24,724

by 손님 [PL/SQL] ORA-06550 [2010.03.16 14:14:05]


패키지

CREATE OR REPLACE PACKAGE PARKDVL.TYPES AS
    Type CURSORTYPE is Ref cursor;
END Types;
/

==================================================================================
프로시저

CREATE OR REPLACE PROCEDURE PARKDVL.PROC_QUESTION_LIST(
    sUserId in   varchar2,
    sTestCode in  varchar2,
    sQuestionNo  in  int,
    O_RESULT out TYPES.CURSORTYPE
) IS
   
 
BEGIN
   open O_RESULT for
    select Q_TITLE, (select f_name from ONLINETEST_ATTACHFILE where f_location = 'q' and idx = OnlineTest_Question.Q_IDX)  FileName
    from OnlineTest_Question where Q_use = 'y' and q_idx in (select Q_idx from OnlineTest_Select where U_userid = sUserId and T_Code = sTestCode);
   close O_RESULT;

END PROC_QUESTION_LIST;

====================================================================================
닷넷 소스

OracleParameter[] para = new OracleParameter[4];

    para[0] = new OracleParameter("sTestCode", OracleType.VarChar, 9);
    para[1] = new OracleParameter("sQuestionNo", OracleType.Int32, 2);
    para[2] = new OracleParameter("sRegNum", OracleType.VarChar, 20);
    para[3] = new OracleParameter("O_RESULT", OracleType.Cursor);

   
    para[0].Value = sTestCode;
    para[1].Value = sQuestionNo;
    para[2].Value = sRegNum;
    para[3].Direction = ParameterDirection.Output;

    DataSet dset = null;
    dset = this.ExecuteDataset("PROC_QUESTION_LIST", para);

    return dset;

=================================================================================
sTestCode, sQuestionNo, sRegNum을 보내서 그에 해당하는 DB row를 가져올려고 하는데요..
계속..

ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to 'PROC_QUESTION_LIST'
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored

이런 에러가 나옵니다.

정말 모르겠습니다.
오라클 초보입니다.

도와주세요~~~
뭐가 문제인가요???

by 손님 [2010.03.17 10:16:54]
인자값 순서를 좀 조정해 보세여

by 손님 [2010.03.19 17:11:32]
인자값이 틀렸습니다. 수정했습니다. 감솨~^^
댓글등록
SQL문을 포맷에 맞게(깔끔하게) 등록하려면 code() 버튼을 클릭하여 작성 하시면 됩니다.
로그인 사용자만 댓글을 작성 할 수 있습니다. 로그인, 회원가입