Call to Package Procedure fails with wrong number or type of parameters

I think its getting to the correct package and procedure since if I change the name slightly, I get an error about it not being defined.
Here is my Parameter set up:
OracleParameter[] theParams = new OracleParameter[26];
theParams[0] = new OracleParameter("P1",OracleDbType.Char,2);
theParams[1] = new OracleParameter("P2", OracleDbType.Char, 12);
theParams[2] = new OracleParameter("P3", OracleDbType.Char, 12);
theParams[3] = new OracleParameter("P4", OracleDbType.Char, 12);
theParams[4] = new OracleParameter("P5", OracleDbType.Double);
theParams[5] = new OracleParameter("P6", OracleDbType.Char, 12);
theParams[6] = new OracleParameter("P7", OracleDbType.Char, 12);
theParams[7] = new OracleParameter("P8", OracleDbType.Char, 12);
theParams[8] = new OracleParameter("P9", OracleDbType.Char, 10);
theParams[9] = new OracleParameter("P10", OracleDbType.Char, 3);
theParams[10] = new OracleParameter("P11", OracleDbType.Char, 2);
theParams[11] = new OracleParameter("P12", OracleDbType.Char, 2);
theParams[12] = new OracleParameter("P13", OracleDbType.Char, 2);
theParams[13] = new OracleParameter("P14", OracleDbType.Char, 6);
theParams[14] = new OracleParameter("P15", OracleDbType.Char, 6);
theParams[15] = new OracleParameter("P16", OracleDbType.Varchar2);
theParams[16] = new OracleParameter("P17", OracleDbType.Char, 2);
theParams[17] = new OracleParameter("P18", OracleDbType.Char, 16);
theParams[17].Direction = System.Data.ParameterDirection.Output;
theParams[18] = new OracleParameter("P19", OracleDbType.Char, 12);
theParams[18].Direction = System.Data.ParameterDirection.Output;
theParams[19] = new OracleParameter("P20", OracleDbType.Varchar2, 12);
theParams[20] = new OracleParameter("P21", OracleDbType.Varchar2);
theParams[21] = new OracleParameter("P22", OracleDbType.Char, 2);
theParams[22] = new OracleParameter("P23", OracleDbType.Char, 2);
theParams[23] = new OracleParameter("P24", OracleDbType.Char, 2);
theParams[24] = new OracleParameter("P25", OracleDbType.Char, 2);
theParams[25] = new OracleParameter("P26", OracleDbType.Char, 2);
Now the problem is that the package definition is declared using types from database table columns, for the most part.
So for those, I used the real types of those columns, like for CHAR(2) I used OracleDbType.Char with length 2.
There are just a few odd balls that I'm not sure about.
For new OracleParameter("P5", OracleDbType.Double);, this is a parameter defined usijng a column type, that is NUMBER(8). Not sure what to use here.
For the line theParams[15] = new OracleParameter("P16", OracleDbType.Varchar2);, the parameter definition for the procedure parameter is VARCHAR2. So I used that with no length specified. Is that correct?
The oddest is this one, theParams[19] = new OracleParameter("P20", OracleDbType.Varchar2, 12);, where the procedure parameter is defined as a type from another package. That in turn is defined as a RECORD:
TYPE t_log_rec IS RECORD (
log_seq t_handle -- VARCHAR2(12)
and t_handle is defined in terms of another table column, and that is defined as VARCHAR2(12).
Any help on how to map those Oracle types back to .Net Oracle data types and parameter definitions is appreciated.

PLSQL Record types cannot be passed directly via OCI (read client) apps, and can only be instantiated/passed from other PLSQL procedures.
You could create a wrapper procedure in the database that accepts all scalar types, which then converts the varchar2 into a t_log_rec and then calls the "real" procedure.
Or, you could instantiate a t_log_rec inside an anonymous block and call the real procedure via that anonymous block.
Varchar2 parameters need size defined. When you assign an IN param a value, size is implicitly defined. OUT parameters need to have size explicitly defined.
Hope it helps
Greg

Similar Messages

  • Getting error wrong number or type of parameters for EAM_PROCESS_WO_PUB

    Hi All,
    I am Getting error wrong number or type of parameters for EAM_WO_PROCESS_PUB.PROCESS_WO API, pls any body can help me,pls send code for
    EAM_WO_PROCESS_PUB.PROCESS_WO API.
    Thanks&Reagrds,
    Hanimi Reddy.

    Hi srini,
    I developed code for work order api EAM_PROCESS_WO_PUB.PROCESS_MASTER_CHILD_WO following and i am getting error wrong number or types of arguments in call to 'PROCESS_MASTER_CHILD_WO, pls see the code and help me
    CREATE OR REPLACE PROCEDURE SANG_WR_TO_WO_API/*(ERRBUF OUT VARCHAR2, RETCODE OUT VARCHAR2)*/ IS
    v_created_by number;
    v_updated_by number;
    v_updated_name varchar2(30);
    V_ENTITY_ID VARCHAR2(30);
    l_EAM_WO_RELATIONS_TBL EAM_PROCESS_WO_PUB.EAM_WO_RELATIONS_TBL_type ;
    --:= EAM_PROCESS_WO_PUB.g_miss_EAM_WO_RELATIONS_rec;
    l_eam_wo_tbl EAM_PROCESS_WO_PUB.eam_wo_rec_type; --:= EAM_PROCESS_WO_PUB.G_MISS_EAM_WO_rec;
    l_eam_op_tbl EAM_PROCESS_WO_PUB.eam_op_tbl_type ;--:= EAM_PROCESS_WO_PUB.G_MISS_eam_op_tbl;
    l_eam_op_network_tbl EAM_PROCESS_WO_PUB.eam_op_network_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_op_network_tbl;
    l_eam_res_tbl EAM_PROCESS_WO_PUB.eam_res_tbl_type;--:= EAM_PROCESS_WO_PUB.G_MISS_eam_res_tbl;
    l_eam_res_inst_tbl EAM_PROCESS_WO_PUB.eam_res_inst_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_res_inst_tbl;
    l_eam_sub_res_tbl EAM_PROCESS_WO_PUB.eam_sub_res_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_sub_res_tbl ;
    -- l_eam_res_usage_tbl EAM_PROCESS_WO_PUB.eam_res_usage_tbl_type := EAM_PROCESS_WO_PUB.G_MISS_eam_res_usage_tbl;
    l_eam_mat_req_tbl EAM_PROCESS_WO_PUB.eam_mat_req_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_mat_req_tbl ;
    l_eam_direct_items_tbl EAM_PROCESS_WO_PUB.eam_direct_items_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_direct_items_tbl ;
    l_x_eam_wo_tbl EAM_PROCESS_WO_PUB.eam_wo_rec_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_wo_rec;
    l__x_EAM_WO_RELATIONS_TBL EAM_PROCESS_WO_PUB.EAM_WO_RELATIONS_TBL_type ;--:= EAM_PROCESS_WO_PUB.g_miss_EAM_WO_RELATIONS_TBL;
    l_x_eam_op_tbl EAM_PROCESS_WO_PUB.eam_op_rec_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_op_rec ;
    l_x_eam_op_network_tbl EAM_PROCESS_WO_PUB.eam_op_network_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_op_network_tbl;
    l_x_eam_res_tbl EAM_PROCESS_WO_PUB.eam_res_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_res_tbl;
    l_x_eam_res_inst_tbl EAM_PROCESS_WO_PUB.eam_res_inst_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_res_inst_tbl ;
    l_x_eam_sub_res_tbl EAM_PROCESS_WO_PUB.eam_sub_res_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_sub_res_tbl;
    -- l_x_eam_res_usage_tbl EAM_PROCESS_WO_PUB.eam_res_usage_tbl_type := EAM_PROCESS_WO_PUB.G_MISS_eam_res_usage_tbl ;
    l_x_eam_mat_req_tbl EAM_PROCESS_WO_PUB.eam_mat_req_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_mat_req_tbl;
    l_x_eam_direct_items_tbl EAM_PROCESS_WO_PUB.eam_direct_items_tbl_type; --:= EAM_PROCESS_WO_PUB.G_MISS_eam_direct_items_tbl ;
    l_x_return_status VARCHAR2(30);
    l_x_msg_count NUMBER;
    l_x_debug VARCHAR2(30);
    l_output_dir VARCHAR2(30);
    l_debug_filename VARCHAR2(30) ;
    l_debug_file_mode VARCHAR2(30) ;
    CURSOR CUR_WTW IS
    SELECT
    EWR.WIP_ENTITY_ID
    ,EWR.WIP_ENTITY_NAME
    ,EWR.ORGANIZATION_ID
    ,WAC.ORGANIZATION_CODE
    ,EWR.DESCRIPTION
    ,EWR.ASSET_GROUP_ID
    ,EWR.ASSET_NUMBER
    ,EWR.ASSET_NUMBER_DESCRIPTION
    ,WAC.ACCOUNTING_CLASS
    ,WAC.MATERIAL_ACCOUNT
    ,WAC.MATERIAL_OVERHEAD_ACCOUNT
    ,WAC.RESOURCE_ACCOUNT
    ,WAC.OUTSIDE_PROCESSING_ACCOUNT
    ,WAC.MATERIAL_VARIANCE_ACCOUNT
    ,WAC.RESOURCE_VARIANCE_ACCOUNT
    ,WAC.OUTSIDE_PROC_VARIANCE_ACCOUNT
    ,WAC.STD_COST_ADJUSTMENT_ACCOUNT
    ,WAC.OVERHEAD_ACCOUNT
    ,WAC.OVERHEAD_VARIANCE_ACCOUNT
    ,EWR.WORK_REQUEST_OWNING_DEPT_ID
    ,EWR.WORK_REQUEST_OWNING_DEPT
    ,EWR.WORK_REQUEST_PRIORITY_ID
    ,EWR.WORK_REQUEST_PRIORITY
    ,EWR.WORK_REQUEST_STATUS_ID
    ,WAC.ORGANIZATION_NAME
    FROM
    WIP_EAM_WORK_REQUESTS_V EWR
    ,WIPFV_ACCOUNTING_CLASSES WAC
    ,WIP_EAM_PARAMETERS WAP
    WHERE
    EWR.ORGANIZATION_ID = WAC.ORGANIZATION_ID
    AND WAC.ORGANIZATION_ID = WAP.ORGANIZATION_ID
    AND WAC.ACCOUNTING_CLASS = WAP.DEFAULT_EAM_CLASS
    AND EWR.WORK_REQUEST_STATUS = 'Awaiting Work Order';
    BEGIN
    --i number := 1;
    FND_GLOBAL.apps_initialize (1001255, 50326, 700, 0);
    V_CREATED_BY := FND_GLOBAL.USER_ID;
    V_UPDATED_BY := FND_GLOBAL.USER_ID;
    v_updated_name := FND_GLOBAL.USER_name;
    for rec in cur_wtw loop
    l_eam_wo_tbl.WIP_ENTITY_ID := rec.wip_entity_id;
    l_eam_wo_tbl.ORGANIZATION_ID := rec.ORGANIZATION_ID ;
    l_eam_wo_tbl.ASSET_NUMBER := rec.ASSET_NUMBER;
    l_eam_wo_tbl.ASSET_GROUP_ID := rec.ASSET_GROUP_ID ;
    l_eam_wo_tbl.DESCRIPTION := rec.DESCRIPTION ;
    --SELECT WIP_ENTITIES_S.NEXTval INTO V_ENTITY_ID FROM DUAL;
    EAM_PROCESS_WO_PUB.PROCESS_MASTER_CHILD_WO
    (P_PO_IDENTIFIER => 'EAM'
    ,P_API_VERSION_NUMBER => 1.0
    ,P_INIT_MSG_LIST => FALSE
    ,P_EAM_WO_RELATIONS_TBL => l_EAM_WO_RELATIONS_TBL
    ,P_EAM_WO_tbl => l_eam_wo_tbl
    , p_eam_op_tbl => l_eam_op_tbl
    , p_eam_op_network_tbl => l_eam_op_network_tbl
    , p_eam_res_tbl => l_eam_res_tbl
    , p_eam_res_inst_tbl => l_eam_res_inst_tbl
    , p_eam_sub_res_tbl => l_eam_sub_res_tbl
    --, p_eam_res_usage_tbl => l_eam_res_usage_tbl
    , p_eam_mat_req_tbl => l_eam_mat_req_tbl
    , p_eam_direct_items_tbl => l_eam_direct_items_tbl
    , x_eam_wo_tbl => l_x_eam_wo_tbl
    , X_EAM_WO_RELATIONS_TBL => l__x_EAM_WO_RELATIONS_TBL
    , x_eam_op_tbl => l_x_eam_op_tbl
    , x_eam_op_network_tbl => l_x_eam_op_network_tbl
    , x_eam_res_tbl => l_x_eam_res_tbl
    , x_eam_res_inst_tbl => l_x_eam_res_inst_tbl
    , x_eam_sub_res_tbl => l_x_eam_sub_res_tbl
    -- , x_eam_res_usage_tbl =>l_x_eam_res_usage_tbl
    , x_eam_mat_req_tbl => l_x_eam_mat_req_tbl
    , x_eam_direct_items_tbl => l_x_eam_direct_items_tbl
    , x_return_status => l_x_return_status
    , x_msg_count => l_x_msg_count
    ,p_commit =>'N'
    , p_debug => 'N'
    , p_output_dir => NULL
    , p_debug_filename => 'EAM_WO_DEBUG.log'
    , p_debug_file_mode => 'w'
    END LOOP;
    END SANG_WR_TO_WO_API;
    COMMIT;
    Thanks ,
    Hanimi

  • Error running a procedure in Python: (wrong number or types of arguments)

    I am getting the following error when trying o execute a stored procedure in python.
    cx_Oracle.DatabaseError: ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'LOAD_FILE1'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    When executed from the SQL Plus or sql developer the same procedure runs without any issue. The following is the code of the called procedure:
    create or replace
    PROCEDURE load_file1 (
    P_FILE_NAME in varchar2)* IS
    src_file BFILE;
    dst_file BLOB;
    lgh_file BINARY_INTEGER;
    BEGIN
    src_file := bfilename('inbox_scnr_dir', P_FILE_NAME);
    -- insert a NULL record to lock
    the above procedure updates creates and updates a record in the table.
    I am calling the above procedure as follows in my python code , see the curs.callproc("load_file1",osfile)
    for filename in files:
    osfile = doc_number(filename)
    curs.callproc("load_file1",osfile)+
    db.commit()
    As you can see I am giving only one argument and the type is string as well, it passes the filename like 'abx.txt' to the procedure. So I am not wrong there.
    Am I calling it in a wrong way or the cx_Oracle have some limitation about procedure callings.
    Can the gurus on the forum help me please. Just need a direction to resolve this , if you can guide me.
    Thanks
    Edited by: user10903866 on Feb 28, 2013 5:54 AM
    Edited by: user10903866 on Feb 28, 2013 6:45 AM

    CREATE OR REPLACE
    PACKAGE TESTER AS
    TYPE t_ref_cur IS REF CURSOR;
    PROCEDURE getRS (p_recordset OUT t_ref_cur);
    END;
    CREATE OR REPLACE
    PACKAGE BODY TESTER AS
    PROCEDURE getRS (p_recordset OUT t_ref_cur) AS
    BEGIN
    OPEN p_recordset FOR
    SELECT
    name,
    value
    FROM
    Parameters;
    END;
    END;For this type of procedure call, you should first have the ref cursor declaration like below
    declare
    cur tester.t_ref_cur;
    begin
    tester.getRS (cur);
    for i in cur
    loop
    dbms_output.put_line(i.name);
    end loop;
    close cur;
    end;Using sys_refcursor also, your handling will be same as shown above......sys_refcursor and normal weak ref cursor only make difference if it is stand alone procedure

  • SSRS 2008 R2 calls Oracle stor proc produces error invalid number or type of parameters

    Hi,
    Our Microsoft SQL Server Reporting Services (SSRS) version 2008 R2 reports have been working for years. They retrieve data from stored procedures on an Oracle 11 DB using the Oracle 11 Client. After the Oracle Client on the SSRS server was upgraded from version 11 to 12, none of the reports work anymore.
    Trying to open any report in IE displays the following error:
    Query execution failed for dataset 'ds_MyDataset'. ---> System.Data.OracleClient.OracleException:
    ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments in call to 'usp_MyOracleStoredProc'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    The simplest example we're using to troubleshoot the problem is a report that has no parameters, which calls an Oracle stored procedure which has no input parameters, and only 1 output parameter (of type "Ref Cursor", the one Oracle needs in order to return the resultset). Even this simple report produces the error shown above.
    I placed a "debugging aid" inside the body of the stored procedure, a SQL insert statement to log to a table, so I can see if the body of the procedure's being executed at all. It never runs. That leads me to think that the error occurs before executing the procedure, when SSRS is probably using something like DeriveParameters() to detect the number and type of parameters the procedure has.
    This leads me to think that when SSRS detects which parameters the Oracle procedure has, the Oracle Client returns 1 parameter (the output cursor). SSRS looks at the number of parameters defined in the report's dataset, and it finds zero b/c the output cursor parameter Oracle uses to return the data doesn't need or can't be defined in SSRS. Then SSRS compares 1 <> 0, and displays the error.
    So, in order to test, I removed the output parameter (the one of type "Ref Cursor") from the Oracle stored procedure, and then the report runs, and the body of the procedure gets executed. There are no errors, but no data b/c the output cursor parameter has being removed from the Oracle procedure.
    This leads me to think that in this case, when SSRS detects which parameters the Oracle procedure has, the Oracle Client returns zero parameters. SSRS looks at the number of parameters defined in the report's dataset, and it matches b/c there aren't any, so SSRS proceeds to execute the procedure.
    Could there be a "miscommunication" between SSRS 2208 R2 and Oracle Client 12 in reference to the number of parameters, b/c with Client 11 all reports work, but with 12 none works?
    Any help with this matter will be greatly appreciated.
    Sincerely,
    Richard

    Our Microsoft SQL Server Reporting Services (SSRS) version 2008 R2 reports have been working for years. They retrieve data from stored procedures on an Oracle 11 DB using the Oracle 11 Client. After the Oracle Client on the SSRS server was upgraded from version 11 to 12, none of the reports work anymore.
    Havent' run across that one before but it sounds like more of a problem with SSRS than anything to do with Oracle.
    But what you posted above raises the obvious question: WHY?
    Why did you upgrad the Oracle client to 12c to begin with if you are still using an Oracle 11g database? Major upgrades like that are normally done for very specific reasons so what were they?
    I suggest you test by reinstalling the 11g client and get your reports working again.
    Also - did you install the new version of ODAC to support the new Oracle client? There could be a compatibility issue if you are using a new Oracle client but the older ODAC version.
    ODAC 12c Release 2 installation instructions
    You also need to make sure the bit versions (32 vs 64 bit) match.

  • Wrong number or types of parameters after upgrading to ODP 11.2.0.1.1 Beta

    Hi,
    I have the below Oracle procedure with two parameters , the first one i IS TABLE OF number INDEX BY BINARY_INTEGER, and the second one is of type Ref cursor of predifned RECORD type.
    PROCEDURE Proc1(p_proj_comp_no_list IN core_util.ref_t,
    p_proj_comp_post_query_cursor OUT t_proj_comp_post_query_cursor
    ) IS
    This has been working fine while we were using DEVART Oracle drivers. however, as soon we move to ODP 11.2.0.1.1 Beta version we get the below error while executing the procedure via ODP.
    {"ORA-06550: line 1, column 7:\nPLS-00306: wrong number or types of arguments in call to 'PROJ_COMP_POST_QUERY'\nORA-06550: line 1, column 7:\nPL/SQL: Statement ignored"}
    Below is the debug watch result of the two parameters of the COMMAND being executed.
    Best Regards,
    Prabhakar
    +          *base     {P_PROJ_COMP_NO_LIST}     System.Data.Common.DbParameter {Oracle.DataAccess.Client.OracleParameter}*
              ArrayBindSize     null     int[]
              ArrayBindStatus     null     Oracle.DataAccess.Client.OracleParameterStatus[]
              CollectionType     None     Oracle.DataAccess.Client.OracleCollectionType
              DbType     String     System.Data.DbType
              Direction     Input     System.Data.ParameterDirection
              IsNullable     false     bool
              Offset     0     int
              OracleDbType     Long     Oracle.DataAccess.Client.OracleDbType
              OracleDbTypeEx     Long     Oracle.DataAccess.Client.OracleDbType
              ParameterName     "P_PROJ_COMP_NO_LIST"     string
              Precision     0     byte
              Scale     0     byte
              Size     1     int
              SourceColumn     ""     string
              SourceColumnNullMapping     false     bool
              SourceVersion     Current     System.Data.DataRowVersion
              Status     Success     Oracle.DataAccess.Client.OracleParameterStatus
              UdtTypeName     ""     string
    +          Value     {long[1]}     object {long[]}
    +          Static members          
    +          Non-Public members          
    -          [1]     {P_PROJ_COMP_POST_QUERY_CURSOR}     object {Oracle.DataAccess.Client.OracleParameter}
    +          *base     {P_PROJ_COMP_POST_QUERY_CURSOR}     System.Data.Common.DbParameter {Oracle.DataAccess.Client.OracleParameter}*
              ArrayBindSize     null     int[]
              ArrayBindStatus     null     Oracle.DataAccess.Client.OracleParameterStatus[]
              CollectionType     None     Oracle.DataAccess.Client.OracleCollectionType
              DbType     Object     System.Data.DbType
              Direction     Output     System.Data.ParameterDirection
              IsNullable     false     bool
              Offset     0     int
              OracleDbType     RefCursor     Oracle.DataAccess.Client.OracleDbType
              OracleDbTypeEx     RefCursor     Oracle.DataAccess.Client.OracleDbType
              ParameterName     "P_PROJ_COMP_POST_QUERY_CURSOR"     string
              Precision     0     byte
              Scale     0     byte
              Size     0     int
              SourceColumn     ""     string
              SourceColumnNullMapping     false     bool
              SourceVersion     Current     System.Data.DataRowVersion
              Status     Success     Oracle.DataAccess.Client.OracleParameterStatus
              UdtTypeName     ""     string
    +          Value     {}     object {System.DBNull}
    +          Static members          
    +          Non-Public members

    Hi,
    Can you please show the actual code that creates and appends the parameters instead, along with cmd.commandtext?
    Thanks
    Greg
    Edited by: gdarling on Jun 30, 2010 11:54 AM
    Also note that unless you're using Oracle Developer Tools for VS to generate the code, this would probably be more appropriate in the ODP forum:
    ODP.NET

  • PLS-00306: wrong number or types of arguments in call to 'PROC_GET_CUSTOMER

    i'm trying to pass multiple value to stored procedure and getting below error
    CREATE OR REPLACE TYPE STRINGTABLE AS TABLE OF VARCHAR2(4000);
    CREATE OR REPLACE
    PACKAGE  PKG_CUSTOMER  AS
    TYPE L_CURSOR IS REF CURSOR;
    PROCEDURE PROC_GET_CUSTOMER( P_SEARCH in STRINGTABLE, SELECTALL OUT L_CURSOR);
    END PKG_CUSTOMER  ;
    CREATE OR REPLACE
    PACKAGE BODY PKG_CUSTOMER  AS
    PROCEDURE PROC_GET_CUSTOMER( P_SEARCH IN STRINGTABLE, SELECTALL OUT L_CURSOR) IS
    BEGIN
         OPEN SELECTALL FOR
          SELECT  PTNR_COUNTRY_CODE, COUNT(*) NOS FROM TAB_MHD_PARTNER
          WHERE PTNR_COUNTRY_CODE in (SELECT * FROM TABLE (P_SEARCH))
          GROUP BY PTNR_COUNTRY_CODE
    END;
    END PKG_CUSTOMER;
    EXEC PKG_CUSTOMER.PROC_GET_CUSTOMER('GB','DE');
    Error starting at line 30 in command:
    EXEC PKG_CUSTOMER.PROC_GET_CUSTOMER('GB','DE')
    Error report:
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'PROC_GET_CUSTOMER'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'PROC_GET_CUSTOMER'
    ORA-06550: line 1, column 43:
    PLS-00363: expression 'DE' cannot be used as an assignment target
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    06550. 00000 -  "line %s, column %s:\n%s"
    *CAUSE:    USUALLY A PL/SQL COMPILATION ERROR.
    *Action:Edited by: RamiahRAGU on Apr 15, 2012 11:08 AM

    The way you are calling the packaged procedure is entirely wrong.
    1. You have one IN parameter which is of table type, and you are trying to pass it as VARCHAR2.
    2. You have an out parameter, and not passing it.
    Moreover, what are you trying to achieve by this code? If you explain teh actual issue, we will be able to help.
    You should call the procedure as below:
    SQL> declare
      2   lc_csr PKG_CUSTOMER.L_CURSOR;
      3  begin
      4   PKG_CUSTOMER.PROC_GET_CUSTOMER(STRINGTABLE('GB','DE'),lc_csr);
      5  end;
      6  /
    PL/SQL procedure successfully completed.

  • SSRS Calling a Stored Procedure error : PLS-00306: wrong number or types of arg...

    Hi,
    My Problem is when im adding dataset with stored procedure, im getting this error.
    I Can access database, 
    Could not create a list of fields for the query. Verify that you can connect to the data source and that your query syntax is correct.
    ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments in call to 'PROCEDURE_NAME' ORA-06550: line 1, column 7: PL/SQL:
    Statement ignored
    stored procedure is simple select :
    CREATE OR REPLACE PROCEDURE [PROCEDURE_NAME](L_CURSOR out SYS_REFCURSOR)
    is
    Begin
    open L_CURSOR for
    SELECT [columnname] FROM
    [tablename]
    End;
    Configuration Details:
    DB: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64biOracle Developer Tools for Visual Studio Copyright (c) 2005,2014 SQL Server Data Tools Type: Oracle , Data Provider : .Net Framework Data Provider For Oracle

    The answer is of inside question. It is about provider. Change my provider ODTwithODAC for 10g (my database version). And problem resolved.
    Thank you for your helps,
    Regards,
    Arda

  • PLS-00306 wrong number or types of arguments in call to 'procedure'

    now i am using oracle10g xe , i get the following error
    create or replace procedure proc_name(slno_in in number,
    name_out out varchar2,fee_out out number)
    is
    v_name student.name%type;
    v_fee student.fee%type;
    begin
    select name,fee into v_name,v_fee from
    student where slno=slno_in;
    name_out := v_name;
    fee_out := v_fee;
    end proc_ref;
    Procedure created.
    SQL> exec proc_name(1);
    BEGIN proc_ref(1); END;
    ERROR at line 1:
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'PROC_REF'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    please help me

    You have a procedure with three arguments
    >
    create or replace procedure proc_name(slno_in in number,
    name_out out varchar2,fee_out out number)You then call it by providing one argument
    >
    SQL> exec proc_name(1);
    BEGIN proc_ref(1); END;
    You get an error saying wrong number of arguments.
    PLS-00306: wrong number or types of arguments in call to 'PROC_REF'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    I don't see how it can be any clearer, call the procedure with three arguments.
    var string varchar2(100)
    var num number
    exec proc_ref(1, :string, :num)

  • Wrong number or types of arguments in call to procedure name

    assuming i have this pl/sql code:
    CREATE OR REPLACE PACKAGE MyPackage AS
    TYPE tab_array IS TABLE OF VARCHAR2(300);
    PROCEDURE my_procedure(in_values IN tab_array);
    END MyPackage;
    CREATE OR REPLACE PACKAGE BODY MyPackage AS
    PROCEDURE my_procedure(in_values IN tab_array) IS
    BEGIN
    DBMS_OUTPUT.PUTLINE('This is only a test');
    END my_procedure;
    END MyPackage;
    when i tried typing this on SQL*Plus
    execute mypackage.my_procedure('value1, value2, value3');
    it gives an error like:
    PLS-00306: wrong number or types of arguments in call to 'MY_PROCEDURE'
    PL/SQL: Statement ignored
    Is my parameters incorrect? What should the parameter be? Please give me a sample code.
    Thanks.

    Hi,
    1. typing error: there should be an underline.
    i.e. DBMS_OUTPUT.PUT_LINE('This is only a test');
    2. Since the tab_array type is user defined (although
    it is VARCHAR2), When the package is called, it cannot
    recognize what you pass in even if you declare it in
    the calling block.
    You should create it as global type, then this type
    can be visible to all other PL/SQL, stored procedure &
    stored package. you can type the following in the SQL/PLUS:
    SQL> CREATE TYPE tab_array AS TABLE OF VARCHAR2(300);
    2 /
    3. Remove the declaration line for the tab_array in the package
    and package body. If you declare it locally in the package,
    it will override the global one and cannot be recognized again.
    So just remove it. it should be compiled and run.
    Hope you succeed.
    Thanks.

  • Calling a package procedure with Date parameter only

    Hi All,
    Please help me to call a package procedure with Date parameter from sql prompt.
    Arif

    Check the below procedure.
    SQL> ed
    Wrote file afiedt.buf
      1  create or replace procedure procdate (p_date_in date)
      2  is
      3  p_date_out date;
      4  begin
      5  p_date_out := add_months(p_date_in,6);
      6  dbms_output.put_line(p_date_out);
      7* end;
    SQL> /
    Procedure created.
    SQL> exec procdate('01-JAN-2010');
    01-JUL-10
    PL/SQL procedure successfully completed.
    SQL> exec procdate(to_date('01/01/2010','DD-MM-YYYY'));
    01-JUL-10
    PL/SQL procedure successfully completed.
    SQL> exec procdate('31-DEC-2010');
    30-JUN-11
    PL/SQL procedure successfully completed.

  • Issue with proc-ora-06550 wrong number or types of arguments in call to

    Hi....
    When i am running the flollwing procedure as
    SQL> exec Prc_WA_Default_Currt_flag(15445);
    the following error is thrown.......could someone help me and please let me know how this can be corrected.
    BEGIN Prc_WA_Default_Currt_flag(15445); END;
    ERROR at line 1:
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to
    'PRC_WA_DEFAULT_CURRT_FLAG'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    ***proc code****
    CREATE OR REPLACE procedure Prc_WA_Default_Currt_flag(Instance_Id_Upd_in in number,dummy1 out number) as
    Instance_Id_Upd1 number;
    dummy2 number;
    cursor c1 is select rwid from wa_temp_default;
    begin
    Instance_Id_Upd1:=Instance_Id_Upd_in;
    for i in c1 loop
    update default_event_log set current_flag=null,Instance_id_upd=Instance_Id_Upd1
    where rowid =i.rwid and load_date<(select currLoadtime from wa_batch where
    jobname='Default_event_log') and current_flag='Y';
    end loop;
    commit;
    for i in c1 loop
    update default_event_log set current_flag='Y'
    where load_date>=(select currLoadtime from wa_batch where
    jobname='Default_event_log') and rowid=i.rwid;
    end loop;
    commit;
    select to_number(Instance_Id_Upd1) into dummy1 from dual;
    end;
    /

    Hi,
    Since it contains an out parameter it has to run this way
    declare
    dummy_out number;
    begin
    prc_wa_default_currt_flag(15445,dummy_out);
    end;Regards
    Anurag

  • PLS-00306: wrong number or types of arguments in call to 'BEFOREREPORTTRIGG

    Hello..
    Hopefully a quick one for somebody..
    Getting following error message..
    [052710_034807986][][EXCEPTION] SQLException encounter while executing data trigger....
    java.sql.SQLException: ORA-06550: line 4, column 20:
    PLS-00306: wrong number or types of arguments in call to 'BEFOREREPORTTRIGGER'
    ORA-06550: line 4, column 1:
    PL/SQL: Statement ignored....when I'm trying to call a trigger in a XSL script that is used to create a XML PUblisher report to run in ORACLE Financials..
    Anyway, Procedure header & Spec at fault is..
    CREATE OR REPLACE PACKAGE Subixclt IS
    FUNCTION BeforeReportTrigger(p_order_by IN VARCHAR2) RETURN VARCHAR2;
    ordered  VARCHAR2(50);
    raisedby VARCHAR2(50);
    status VARCHAR2(50);
    claimant VARCHAR2(50);
    expense_date_from DATE;
    expense_date_to DATE;
    END;
    CREATE OR REPLACE PACKAGE BODY Subixclt IS
    FUNCTION BeforeReportTrigger(p_order_by IN VARCHAR2)RETURN VARCHAR2 IS
    BEGIN
    DECLARE
    ordered  VARCHAR2(50);
    raisedby VARCHAR2(50);
    status VARCHAR2(50);
    claimant VARCHAR2(100);
    expense_date_from DATE;
    expense_date_to DATE;
    BEGIN
    IF (p_order_by='Expense Report Number') THEN
         ordered :='order by 1 asc;';
      ELSIF (p_order_by='Person Claiming') THEN
         ordered :='order by 2 asc;';
      ELSIF (p_order_by='Submit Date') THEN
      ordered :='order by 4 asc;';
      END IF;
    RETURN(p_order_by);
    END;
    END;
    END;PLease ask if yous need any further info..
    muchos gracias..
    Steven

    OK people sorry - I trust this is what you'll need..
    This is the data template where the call to the trigger is placed..
    <?xml version="1.0" encoding="utf-8"?>
    <dataTemplate name="UofS_OutstandngExpenses_Report" defaultPackage="SUBIXCLT" dataSourceRef="FINDEV" version="1.0">
    <properties>
    <property name="xml_tag_case"       value="upper" />
    <property name="include_parameters" value="true"  />
    <property name="debug_mode"         value="on"    />
    </properties>
    <parameters>
    <parameter name="claimant" dataType="character" />
    <parameter name="expense_date_from" dataType="date" />
    <parameter name="expense_date_to" dataType="date" />
    <parameter name="raisedby" dataType="character" />
    <parameter name="status" dataType="character" />
    </parameters>
    <dataQuery> 
    <sqlStatement name="Q1">
    <![CDATA[
    SELECT DISTINCT
    erh.invoice_num,
    pap.full_name EMP_CLAIMING,
    DECODE(NVL(erh.expense_status_code, 'Not yet Submitted (NULL)'), 'CANCELLED', 'CANCELLED',
         'EMPAPPR', 'Pending Individuals Approval',      'ERROR', 'Pending System Administrator Action',
         'HOLD_PENDING_RECEIPTS     ', 'Hold Pending Receipts', 'INPROGRESS', 'In Progress', 'INVOICED', 'Ready for Payment',
         'MGRAPPR', 'Pending Payables Approval', 'MGRPAYAPPR', 'Ready for Invoicing', 'PAID', 'Paid',
         'PARPAID', 'Partially Paid',     'PAYAPPR', 'Payables Approved',     'PENDMGR', 'Pending Manager Approval',
         'PEND_HOLDS_CLEARANCE', 'Pending Payment Verification',     'REJECTED', 'Rejected',     'RESOLUTN',     'Pending Your Resolution',
         'RETURNED',     'Returned',     'SAVED',     'Saved',     'SUBMITTED',     'Submitted',     'UNUSED',     'UNUSED',
         'WITHDRAWN','Withdrawn',     'Not yet Submitted (NULL)') "EXPENSE_STATUS" ,
    NVL(TO_CHAR(erh.report_submitted_date,'dd-MON-yyyy'),'NULL') SUBMIT_DATE,
    NVL(TO_CHAR(erh.expense_last_status_date,'dd-MON-yyyy'),'NULL') LAST_UPDATE,
    erh.override_approver_name ER_Approver,
    fu.description EXP_ADMIN,
    erh.total,
    erh.description 
    FROM
    AP_EXPENSE_REPORT_HEADERS_all erh,
    per_all_people_f pap, fnd_user fu
    WHERE erh.employee_id = pap.person_id
    AND fu.user_id = erh.created_by
    AND NVL(erh.expense_status_code, 'Not yet Submitted') NOT IN  ('MGRAPPR', 'INVOICED', 'PAID', 'PARPAID')
    AND pap.full_name = NVL(:claimant, pap.full_name)
    AND TRUNC(erh.report_submitted_date) BETWEEN NVL(:expense_date_from, '01-JAN-1999') AND NVL(:expense_date_to,'31-DEC-2299')
    AND fu.description = NVL(:raisedby,fu.description)
    AND erh.expense_status_code = NVL(:status,erh.expense_status_code) &ordered]]>
    </sqlStatement>
    </dataQuery>
    <dataTrigger name="beforeReportTrigger" source="SUBIXCLT.beforeReportTrigger"/>
    <dataStructure>
    <group name="G_XP_CLM_TRACKNG" source="Q1">
    <element name="INVOICE_NUM" value="INVOICE_NUM" />
    <element name="EMP_CLAIMING" value="EMP_CLAIMING" />
    <element name="EXPENSE_STATUS" value="EXPENSE_STATUS" />
    <element name="SUBMIT_DATE" value="SUBMIT_DATE" />
    <element name="LAST_UPDATE" value="LAST_UPDATE" />
    </group>
    </dataStructure>
    </dataTemplate>..when I try to run the Concurrent Program (ORACLE uses a Java Program to run it somehow..) this is the log file produced (note, I dont use the parameter &ordered that the trigger is for)..
    XDO Data Engine Version No: 5.6.3
    Resp: 20707
    Org ID : 102
    Request ID: 2481618
    All Parameters: raisedby=:status=:claimant=:expense_date_from=:expense_date_to=:p_order_by=
    Data Template Code: SUBIXCLT
    Data Template Application Short Name: PO
    Debug Flag: N
    {raisedby=, p_order_by=, claimant=, expense_date_to=, expense_date_from=, status=}
    Calling XDO Data Engine...
    [052810_033436415][][STATEMENT] Start process Data
    [052810_033436416][][STATEMENT] Process Data ...
    [052810_033436418][][STATEMENT] Executing data triggers...
    [052810_033436418][][STATEMENT] BEGIN
    SUBIXCLT.claimant := :claimant ;
    SUBIXCLT.expense_date_from := :expense_date_from ;
    SUBIXCLT.expense_date_to := :expense_date_to ;
    SUBIXCLT.raisedby := :raisedby ;
    SUBIXCLT.status := :status ;
    :XDO_OUT_PARAMETER := 1;
    END;
    [052810_033436421][][STATEMENT] 1: :
    [052810_033436421][][STATEMENT] 2:null :
    [052810_033436421][][STATEMENT] 3:null :
    [052810_033436422][][STATEMENT] 4: :
    [052810_033436422][][STATEMENT] 5: :
    [052810_033436504][][STATEMENT] Executing data triggers...
    [052810_033436504][][STATEMENT] Declare
    l_flag Boolean;
    BEGIN
    l_flag := SUBIXCLT.beforeReportTrigger ;
    if (l_flag) then
    :XDO_OUT_PARAMETER := 1;
    end if;
    end;
    [052810_033436518][][EXCEPTION] SQLException encounter while executing data trigger....
    java.sql.SQLException: ORA-06550: line 4, column 20:
    PLS-00306: wrong number or types of arguments in call to 'BEFOREREPORTTRIGGER'
    ORA-06550: line 4, column 1:
    PL/SQL: Statement ignored
         at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
         at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:289)
         at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:590)
         at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1973)
         at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1119)
         at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2191)
         at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:2064)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2989)
         at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:658)
         at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:736)
         at oracle.apps.xdo.dataengine.XMLPGEN.executeTriggers(XMLPGEN.java:650)
         at oracle.apps.xdo.dataengine.XMLPGEN.processData(XMLPGEN.java:263)
         at oracle.apps.xdo.dataengine.XMLPGEN.processXML(XMLPGEN.java:215)
         at oracle.apps.xdo.dataengine.XMLPGEN.writeXML(XMLPGEN.java:254)
         at oracle.apps.xdo.dataengine.DataProcessor.processDataStructre(DataProcessor.java:390)
         at oracle.apps.xdo.dataengine.DataProcessor.processData(DataProcessor.java:355)
         at oracle.apps.xdo.oa.util.DataTemplate.processData(DataTemplate.java:348)
         at oracle.apps.xdo.oa.cp.JCP4XDODataEngine.runProgram(JCP4XDODataEngine.java:293)
         at oracle.apps.fnd.cp.request.Run.main(Run.java:161)
    +---------------------------------------------------------------------------+
    Executing request completion options...
    +------------- 1) PUBLISH -------------+
    Beginning post-processing of request 2481618 on node FINDEV at 28-MAY-2010 15:34:37.
    Post-processing of request 2481618 failed at 28-MAY-2010 15:34:39 with the error message:
    One or more post-processing actions failed. Consult the OPP service log for details... and OPP service log contains..
    Template code: SUBIXCLT
    Template app:  PO
    Language:      en
    Territory:     GB
    Output type:   PDF
    [5/28/10 3:34:39 PM] [UNEXPECTED] [46385:RT2481618] java.lang.reflect.InvocationTargetException
         at sun.reflect.GeneratedMethodAccessor119.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeParse(XSLT10gR1.java:566)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:231)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:182)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:1044)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:997)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:212)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1665)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:975)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.runProcessTemplate(TemplateHelper.java:5926)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3458)
         at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3547)
         at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:290)
         at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:157)
    Caused by: org.xml.sax.SAXParseException: <Line 1, Column 1>: XML-20108: (Fatal Error) Start of root element expected.
         at oracle.xdo.parser.v2.XMLError.flushErrorHandler(XMLError.java:441)
         at oracle.xdo.parser.v2.XMLError.flushErrors1(XMLError.java:303)
         at oracle.xdo.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:343)
         at oracle.xdo.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:285)
         at oracle.xdo.parser.v2.XMLParser.parse(XMLParser.java:289)
         ... 16 moreMany thanks for looking..
    Steven

  • Error PLS-00306: wrong number or types of arguments in call to

    I am getting the following Error when calling stored Procedure, I have tried with Last Parameter PRESULT and WITHOUT IT, it fails in both the instance.
    =======================================================================
    "System.Data.OracleClient.OracleException: ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'UPDATECOTRACKING'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    =======================================================================
    signature of Stored Procedure is as follow
    (pmaster_key IN sca_costtrackinglog.master_key%type,
         pdoc_master_key IN sca_costtrackinglog.master_key%type,     
    pfrenumber IN sca_costtrackinglog.fre_number%type,     
    pnotice1 IN sca_costtrackinglog.notice1%type,
    pnotice2 IN sca_costtrackinglog.notice2%type,
    padditreceived IN sca_costtrackinglog.additreceived%type,
    pfreanticipate IN sca_costtrackinglog.freanticipate%type,
    pdateofnot IN sca_costtrackinglog.dateofnot%type,
    pdateofmeeting IN sca_costtrackinglog.dateofmeeting%type,
    psenttocontractor IN sca_costtrackinglog.senttocontractor%type,
    pcouforexecution IN sca_costtrackinglog.couforexecution%type,
    pcomments IN sca_costtrackinglog.comments%type,
    pcreateby IN sca_costtrackinglog.createby%type,
    peditby IN sca_costtrackinglog.editby%type,
         presult OUT number) is
    This is the Trace of Parameters from actual Call, that fails with above error.
    Parameter Name : PMASTER_KEY(Input),Type(AnsiString) Size(26), Value = 000328JYA30008HSWBCK01NYC
    Parameter Name : pdoc_master_key(Input),Type(AnsiString) Size(26), Value = 310657KLF30025HSWBCK01NYC
    Parameter Name : PFRENUMBER(Input),Type(AnsiString) Size(12), Value = 00015
    Parameter Name : PNOTICE1(Input),Type(DateTime) Size(1), Value = 3/25/2010
    Parameter Name : PNOTICE2(Input),Type(DateTime) Size(1), Value =
    Parameter Name : PADDITRECEIVED(Input),Type(DateTime) Size(1), Value =
    Parameter Name : PFREANTICIPATE(Input),Type(DateTime) Size(1), Value =
    Parameter Name : PDATEOFNOT(Input),Type(DateTime) Size(1), Value =
    Parameter Name : PDATEOFMEETING(Input),Type(DateTime) Size(1), Value =
    Parameter Name : PSENTTOCONTRACTOR(Input),Type(DateTime) Size(1), Value =
    Parameter Name : pcouforexecution(Input),Type(DateTime) Size(1), Value =
    Parameter Name : pcomments(Input),Type(AnsiString) Size(250), Value =
    Parameter Name : PCREATEBY(Input),Type(AnsiString) Size(50), Value = NYCSCA\tmpns2
    Parameter Name : PEDITBY(Input),Type(AnsiString) Size(50), Value = NYCSCA\tmpns2
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    Below is the trace from Data.OracleClient.OracleCommandBuilder.DeriveParameters(Cmd)
    Parameter Name : PMASTER_KEY(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PDOC_MASTER_KEY(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PFRENUMBER(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PNOTICE1(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PNOTICE2(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PADDITRECEIVED(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PFREANTICIPATE(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PDATEOFNOT(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PDATEOFMEETING(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PSENTTOCONTRACTOR(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PCOUFOREXECUTION(Input),Type(DateTime) Size(0), Value =
    Parameter Name : PCOMMENTS(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PCREATEBY(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PEDITBY(Input),Type(AnsiString) Size(2000), Value =
    Parameter Name : PRESULT(Output),Type(VarNumeric) Size(0), Value =
    ******************************************************************************************************************

    In the Oracle database, the body of the package FWA_PRI API, the procedure ValidatePri declares P_PriREc as being :
    PAYMENT_REQUEST_IMPORT%ROWTYPE
    As you can see above, the DoPri Procedure expects a type p_PriRec as its second argument.
    Therefore in my procedure I do the following:
    create or replace procedure spMatchPayment is
    BEGIN
    DECLARE
           CURSOR StageCurs IS SELECT * FROM PAYMENT_REQUEST_IMPORT;
                  p_payment_req_import PAYMENT_REQUEST_IMPORT%ROWTYPE;
                  BEGIN
                       OPEN StageCurs();
                            LOOP
                                FETCH StageCurs INTO P_payment_req_import;
                                EXIT WHEN StageCurs%NOTFOUND;
                                fwa_pri.DoPri(NULL, fwa_pri.DoPri('M',P_PriRec => p_payment_req_import);                           
                             END LOOP;
                        CLOSE StageCurs;
                   END;
    end spMatchPayment;
    Now, when I am trying to compile I am getting the Compilation errors for PROCEDURE IMPACT.SPMATCHPAYMENT
    Error: PLS-00306: wrong number or types of arguments in call to 'DOPRI'
    Line: 16
    Text: fwa_pri.DoPri(NULL,P_PriRec => p_payment_req_import);
    I don't see what's wrong on my code......HELP!!

  • PLSQL Concurrent error: wrong number or types of arguments in call

    Hi there,
    I've defined a PLSQL Concurrent with 2 parameters:
    10) DELIVERABLE_ID using valueset 10/Number (A 10 digit positive number field with no validation)
    20) STATUS using valueset 10 Characters (10 Characters free text with no validation)
    My request run into error, with parameter values DELIVERABLE_ID = 105367,STATUS=New
    Cause: FDPSTP failed due to ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'EBOARD_WF_START'
    ORA-06550: line 1, column 7:
    But I ran the the same PLSQL from toad
    ADB_PA_BC_WF.EBOARD_WF_START (105367,'New');
    I dont have any error, it completed successfully.
    Any clue what gone wrong?

    You need to define package / procedure with RETCODE and ERRBUF arguments to call as concurrent program.
    procedure my_cp
    ( errbuf out varchar2,
    retcode out varchar2,
    p_arg1 in varchar2,
    p_arg2 in varchar2
    Regards,
    Gareth

  • Pl. help debug - PLS-00306: wrong number or types of arguments in call

    Hi,
    I am trying to create a wrapper function to all a procedure in Oracle EBusiness Suite 11i.
    When I compile the following code
    ==========
    CREATE OR REPLACE PROCEDURE gme.KIL_ProcessAlloc IS
    vFileName VARCHAR2(30) := '1006251.csv';
    vLoc VARCHAR2(20) := '/u041/applmgr/opm/opmappl/utllog';
    v_InHandle utl_file.file_type;
    vNewLine VARCHAR2(1000);
    vLineNo PLS_INTEGER;
    c1 PLS_INTEGER;
    c2 PLS_INTEGER;
    c3 PLS_INTEGER;
    c4 PLS_INTEGER;
    c5 PLS_INTEGER;
    c6 PLS_INTEGER;
    c7 PLS_INTEGER;
    c8 PLS_INTEGER;
    c9 PLS_INTEGER;
    c10 PLS_INTEGER;
    c11 PLS_INTEGER;
    c12 PLS_INTEGER;
    c13 PLS_INTEGER;
    c14 PLS_INTEGER;
    c15 PLS_INTEGER;
    c16 PLS_INTEGER;
    c17 PLS_INTEGER;
    c18 PLS_INTEGER;
    c19 PLS_INTEGER;
    c20 PLS_INTEGER;
    c21 PLS_INTEGER;
    c22 PLS_INTEGER;
    c23 PLS_INTEGER;
    c24 PLS_INTEGER;
    c25 PLS_INTEGER;
    c26 PLS_INTEGER;
    c27 PLS_INTEGER;
    c28 PLS_INTEGER;
    c29 PLS_INTEGER;
    c30 PLS_INTEGER;
    c31 PLS_INTEGER;
    c32 PLS_INTEGER;
    c33 PLS_INTEGER;
    c34 PLS_INTEGER;
    TYPE AllocArray IS TABLE OF GME_INVENTORY_TXNS_GTMP%ROWTYPE
    INDEX BY BINARY_INTEGER;
    l_Allocdata AllocArray;
    TYPE MtlDetailArray IS TABLE OF gme_material_details%ROWTYPE
    INDEX BY BINARY_INTEGER;
    l_MtlDetaildata MtlDetailArray;
    TYPE xTranArray IS TABLE OF GME_INVENTORY_TXNS_GTMP%ROWTYPE
    INDEX BY BINARY_INTEGER;
    l_xtrandata xTranArray;
    TYPE defTranArray IS TABLE OF GME_INVENTORY_TXNS_GTMP%ROWTYPE
    INDEX BY BINARY_INTEGER;
    l_deftrandata defTranArray;
    t_messagecount number;
    t_messagelist varchar2(10000);
    t_returnstatus varchar2(1);
    BEGIN
    v_InHandle := utl_file.fopen(vLoc, vFileName, 'r');
    vLineNo := 1;
    LOOP
    BEGIN
    utl_file.get_line(v_InHandle, vNewLine);
    EXCEPTION
    WHEN NO_DATA_FOUND THEN
    EXIT;
    END;
    vNewLine := TRANSLATE(vNewLine, 'A''', 'A');
    c1 := INSTR(vNewLine, ',', 1,1);
    c2 := INSTR(vNewLine, ',', 1,2);
    c3 := INSTR(vNewLine, ',', 1,3);
    c4 := INSTR(vNewLine, ',', 1,4);
    c5 := INSTR(vNewLine, ',', 1,5);
    c6 := INSTR(vNewLine, ',', 1,6);
    c7 := INSTR(vNewLine, ',', 1,7);
    c8 := INSTR(vNewLine, ',', 1,8);
    c9 := INSTR(vNewLine, ',', 1,9);
    c10 := INSTR(vNewLine, ',', 1,10);
    c11 := INSTR(vNewLine, ',', 1,11);
    c12 := INSTR(vNewLine, ',', 1,12);
    c13 := INSTR(vNewLine, ',', 1,13);
    c14 := INSTR(vNewLine, ',', 1,14);
    c15 := INSTR(vNewLine, ',', 1,15);
    c16 := INSTR(vNewLine, ',', 1,16);
    c17 := INSTR(vNewLine, ',', 1,17);
    c18 := INSTR(vNewLine, ',', 1,18);
    c19 := INSTR(vNewLine, ',', 1,19);
    c20 := INSTR(vNewLine, ',', 1,20);
    c21 := INSTR(vNewLine, ',', 1,21);
    c22 := INSTR(vNewLine, ',', 1,22);
    c23 := INSTR(vNewLine, ',', 1,23);
    c24 := INSTR(vNewLine, ',', 1,24);
    c25 := INSTR(vNewLine, ',', 1,25);
    c26 := INSTR(vNewLine, ',', 1,26);
    c27 := INSTR(vNewLine, ',', 1,27);
    c28 := INSTR(vNewLine, ',', 1,28);
    c29 := INSTR(vNewLine, ',', 1,29);
    c30 := INSTR(vNewLine, ',', 1,30);
    c31 := INSTR(vNewLine, ',', 1,31);
    c32 := INSTR(vNewLine, ',', 1,32);
    c33 := INSTR(vNewLine, ',', 1,33);
    c34 := INSTR(vNewLine, ',', 1,34);
    -- l_allocdata(vLineNo).sourceno := SUBSTR(vNewLine,1,c1-1);
    -- l_allocdata(vLineNo).sizeno := SUBSTR(vNewLine,c1+1,c2-c1-1);
    -- l_allocdata(vLineNo).status := SUBSTR(vNewLine,c2+1,c3-c2-1);
    -- l_allocdata(vLineNo).latitude := SUBSTR(vNewLine,c3+1,c4-c3-1);
    -- l_allocdata(vLineNo).longitude := SUBSTR(vNewLine,c4+1,c5-c4-1);
    -- l_allocdata(vLineNo).testfor := SUBSTR(vNewLine,c5+1);
    l_allocdata(vLineNo).trans_id := SUBSTR(vNewLine,1,c1-1);
    l_allocdata(vLineNo).item_id := SUBSTR(vNewLine,c1+1,c2-c1-1);
    l_allocdata(vLineNo).co_code := SUBSTR(vNewLine,c2+1,c3-c2-1);
    l_allocdata(vLineNo).orgn_code := SUBSTR(vNewLine,c3+1,c4-c3-1);
    l_allocdata(vLineNo).whse_code := SUBSTR(vNewLine,c4+1,c5-c4-1);
    l_allocdata(vLineNo).lot_id := SUBSTR(vNewLine,c5+1,c6-c5-1);
    l_allocdata(vLineNo).location := SUBSTR(vNewLine,c6+1,c7-c6-1);
    l_allocdata(vLineNo).doc_id := SUBSTR(vNewLine,c7+1,c8-c7-1);
    l_allocdata(vLineNo).doc_type := SUBSTR(vNewLine,c8+1,c9-c8-1);
    l_allocdata(vLineNo).doc_line := SUBSTR(vNewLine,c9+1,c10-c9-1);
    l_allocdata(vLineNo).line_type := SUBSTR(vNewLine,c10+1,c11-c10-1);
    l_allocdata(vLineNo).reason_code := SUBSTR(vNewLine,c11+1,c12-c11-1);
    l_allocdata(vLineNo).trans_date := SUBSTR(vNewLine,c12+1,c13-c12-1);
    l_allocdata(vLineNo).trans_qty := SUBSTR(vNewLine,c13+1,c14-c13-1);
    l_allocdata(vLineNo).trans_qty2 := SUBSTR(vNewLine,c14+1,c15-c14-1);
    l_allocdata(vLineNo).qc_grade := SUBSTR(vNewLine,c15+1,c16-c15-1);
    l_allocdata(vLineNo).lot_status := SUBSTR(vNewLine,c16+1,c17-c16-1);
    l_allocdata(vLineNo).trans_stat := SUBSTR(vNewLine,c17+1,c18-c17-1);
    l_allocdata(vLineNo).trans_um := SUBSTR(vNewLine,c18+1,c19-c18-1);
    l_allocdata(vLineNo).trans_um2 := SUBSTR(vNewLine,c19+1,c20-c19-1);
    l_allocdata(vLineNo).completed_ind := SUBSTR(vNewLine,c20+1,c21-c20-1);
    l_allocdata(vLineNo).staged_ind := SUBSTR(vNewLine,c21+1,c22-c21-1);
    l_allocdata(vLineNo).gl_posted_ind := SUBSTR(vNewLine,c22+1,c23-c22-1);
    l_allocdata(vLineNo).event_id := SUBSTR(vNewLine,c23+1,c24-c23-1);
    l_allocdata(vLineNo).text_code := SUBSTR(vNewLine,c24+1,c25-c24-1);
    l_allocdata(vLineNo).transaction_no := SUBSTR(vNewLine,c25+1,c26-c25-1);
    l_allocdata(vLineNo).action_code := SUBSTR(vNewLine,c26+1,c27-c26-1);
    l_allocdata(vLineNo).material_detail_id := SUBSTR(vNewLine,c27+1,c28-c27-1);
    l_allocdata(vLineNo).organization_id := SUBSTR(vNewLine,c28+1,c29-c28-1);
    l_allocdata(vLineNo).locator_id := SUBSTR(vNewLine,c29+1,c30-c29-1);
    l_allocdata(vLineNo).subinventory := SUBSTR(vNewLine,c30+1,c31-c30-1);
    l_allocdata(vLineNo).alloc_um := SUBSTR(vNewLine,c31+1,c32-c31-1);
    l_allocdata(vLineNo).alloc_qty := SUBSTR(vNewLine,c32+1,c33-c32-1);
    l_allocdata(vLineNo).def_trans_ind := SUBSTR(vNewLine,c33+1,c34-c33-1);
    vLineNo := vLineNo+1;
    END LOOP;
    utl_file.fclose(v_InHandle);
    FOR i IN 1..vLineNo-1 loop
    GME_API_PUB.insert_line_allocation (
         1,
         100,
         FALSE,
         True,
         l_allocdata(i),
         null,
         null,
         false,
         false,
         false,
         l_MtlDetailData,
         l_xtrandata,
         l_deftrandata,
         t_messagecount,
         t_messagelist,
         t_returnstatus);
    end loop;
         IF (t_returnstatus <> 'S') THEN
    for i IN 1 .. t_messagecount LOOP
    dbms_output.put_line('The text is '||FND_MSG_PUB.get(i,t_messagelist));
    END LOOP;
    END IF;
    -- COMMIT;
    EXCEPTION
    WHEN OTHERS THEN
    RAISE;
    END KIL_ProcessAlloc;
    ===============
    I get this
    Warning: Procedure created with compilation errors.
    SQL> sho err
    Errors for PROCEDURE GME.KIL_PROCESSALLOC:
    LINE/COL ERROR
    145/8 PLS-00306: wrong number or types of arguments in call to
    'INSERT_LINE_ALLOCATION'
    145/8 PL/SQL: Statement ignored
    =================
    The package specs of GME_API_PU is under:
    ===============
    PROCEDURE insert_line_allocation (
    p_api_version IN NUMBER := gme_api_pub.api_version
    ,p_validation_level IN NUMBER := gme_api_pub.max_errors
    ,p_init_msg_list IN BOOLEAN := FALSE
    ,p_commit IN BOOLEAN := FALSE
    ,p_tran_row IN gme_inventory_txns_gtmp%ROWTYPE
    ,p_lot_no      IN     VARCHAR2 DEFAULT NULL
    ,p_sublot_no      IN     VARCHAR2 DEFAULT NULL
    ,p_create_lot     IN BOOLEAN DEFAULT FALSE
    ,p_ignore_shortage     IN BOOLEAN DEFAULT FALSE
    ,p_scale_phantom     IN BOOLEAN DEFAULT FALSE
    ,x_material_detail     OUT gme_material_details%ROWTYPE
    ,x_tran_row     OUT gme_inventory_txns_gtmp%ROWTYPE
    ,x_def_tran_row     OUT gme_inventory_txns_gtmp%ROWTYPE
    ,x_message_count OUT NUMBER
    ,x_message_list OUT VARCHAR2
    ,x_return_status     OUT VARCHAR2);
    GME_API_PUB.insert_line_allocation
    ===========
    What am I doing wrong...why am I getting PLS-00306.
    Can someone help?
    Thank you
    Sundar
    [email protected]

    Hi John,
    Thanks a ton - a nice Christmas gift. Thank you for being a Santa :-).
    I used the same subscript as the one used for in parameter and the procedure compiled without errors.
    A corollary: If (any of the) Out parameter is null (all columns of the row/array), will the array row element still be stored ? May be I cross the bridge when I come to it.
    Merry Christmas.
    Sundar

Maybe you are looking for

  • Pdf output of web dynpro does not display in cProjects

    Hi, We created a custom web dynpro which calls a smartform and gives a pdf output. This pdf output is seen on the cProjects portal under a customized tab. The issue is, some users are able to see this pdf output on teh portal without any issues but o

  • Where are the shadows and highlights sliders?

    Just confirming that they eliminated the 2 most useful editing sliders. And the option to edit in an external editor is gone, too? This app is not ready for prime time.

  • Disc Drive Problem

    Hi guys, I got a problem with my macbook pro disc drive. I accidentally changed the Dvd Region Code five times and now I only can play American Dvd's anymore and no European ones. And I was told that the only way to correct this problem would be by r

  • Dreaded 90 degree and screen goes black

    I have been putting up with my ibook screen going dim whenever you open the screen to 90 degrees for about five months. However, it is now starting to become really annoying because I have to switch the computer off, close the screen and reboot it in

  • Lg tablet is stuck

    My lg pad is stuck on some status widget...help please!