Enqueue and xmltype and PLS-00306 error

I tried to create such a procedure but PL-SQL shows errors.
PLS-00306 Incorrect number or types of arguments for call enqueue
create or replace procedure enqueue_xmltype( queueName in varchar2,msgClob in CLOB) is
msgProp dbms_aq.message_properties_t;
enqOpt dbms_aq.enqueue_options_t;
msgHdl RAW(16);
message SYS.XMLTYPE;
begin
message:=SYS.XMLType.CreateXml(msgClob);
dbms_aq.enqueue(queue_name => queueName,
enqueue_options => enqOpt,
message_properties => msgProp,
payload => message,
msgid => msgHdl);
COMMIT;
end;
What is wrong ? I created queue table with XMLType payload.
Please help !!!
Piotr

Enqueue of XMLType directly is not supported in 9.1. You need to create an ADT with an embedded XML type. Check out
http://docs.oracle.com/cd_a91034/DOC/appdev.901/a88890/adq08qap3.htm#91301
In Oracle9i release2 , you will be able to do what you are doing - ie. create queues with XMLtype payloads

Similar Messages

  • Cyclic PLS-00538 and PLS-00539 errors?

    I've defined a supertype, t_cliente, and derived two subtypes, t_cliente_pers and t_cliente_soc. The first one has 6 member functions and the latter ones override only two of them.
    Every time I launch the script for creation I get PLS-00538 and PLS-00539 errors, but I'm not able to find out why.
    The explanation for PLS-00538 is: subprogram or cursor "string" is declared in an object type specification and must be defined in the object type body.
    For PLS-00539 is: subprogram "string" is declared in an object type body and must be defined in the object type specification.
    It's a cycle! And after all I defined these 2 functions in type specification and type body.
    I'm using 10g XE. Here's the code:
    create TYPE t_indirizzo AS OBJECT (
    via VARCHAR(45),
    numero NUMBER(4),
    cap INTEGER(5),
    citta VARCHAR(30),
    provincia VARCHAR(30),
    regione VARCHAR(30),
    MEMBER FUNCTION indirizzoCompleto RETURN VARCHAR
    create TYPE t_telefono AS OBJECT (
    num_tel NUMBER(15)
    create TYPE t_telefono_array IS VARRAY(3) OF t_telefono
    create TYPE t_anagrafica AS OBJECT (
    nome VARCHAR(45),
    cognome VARCHAR(45),
    sesso CHAR(1),
    cod_fiscale VARCHAR(16),
    data_nascita DATE
    create TYPE t_ragioneSociale AS OBJECT (
    nome_soc VARCHAR(45),
    data_cost DATE,
    part_iva NUMBER(11)
    create TYPE t_persona AS OBJECT (
    dati_anagrafici t_anagrafica,
    indirizzo t_indirizzo,
    email VARCHAR(45),
    telefono t_telefono_array
    create TYPE t_societa AS OBJECT (
    ragione_sociale t_ragioneSociale,
    indirizzo t_indirizzo,
    email VARCHAR(45),
    telefono t_telefono_array,
    persona_rif REF t_persona
    create TYPE t_cliente AS OBJECT (
    cod_cliente NUMBER(8),
    MEMBER FUNCTION incFatti RETURN NUMBER,
    MEMBER FUNCTION incSubiti RETURN NUMBER,
    MEMBER FUNCTION incFattiPeriodo RETURN NUMBER, /* this is the first function that gives me problems */
    MEMBER FUNCTION incSubitiPeriodo RETURN NUMBER, /* this is the second one */
    MEMBER FUNCTION nomeCliente RETURN VARCHAR,
    MEMBER FUNCTION tipoCliente RETURN VARCHAR
    ) NOT FINAL
    create or replace
    TYPE BODY t_cliente AS
    MEMBER FUNCTION incFatti RETURN NUMBER
    IS incidenti NUMBER;
    BEGIN
    SELECT count(i. cod_incidente) INTO incidenti
    FROM incidente i, mezzo m
    WHERE SELF.cod_cliente = m.proprietario.cod_cliente AND m.num_targa = i.mezzo. num_targa AND i. responsabilita = 'c';
    RETURN (incidenti);
    END;
    MEMBER FUNCTION incSubiti RETURN NUMBER
    IS incidenti NUMBER;
    BEGIN
    SELECT count(i. cod_incidente) INTO incidenti /* here's the first PLS-00538 error */
    FROM incidente i, mezzo m /* here's the second PLS-00538 error */
    WHERE SELF.cod_cliente = m.proprietario.cod_cliente AND m.num_targa = i.mezzo. num_targa AND i. responsabilita = 's';
    RETURN (incidenti);
    END;
    MEMBER FUNCTION incFattiPeriodo(da DATE, a DATE) RETURN NUMBER /* here's the first PLS-00539 error */
    IS incidenti NUMBER;
    BEGIN
    SELECT count(i. cod_incidente) INTO incidenti
    FROM incidente i , mezzo m
    WHERE SELF. cod_cliente = m.proprietario.cod_cliente AND m. num_targa = i.mezzo. num_targa AND i. responsabilita = 'c' AND (i.data_inc BETWEEN da and a);
    RETURN (incidenti);
    END;
    MEMBER FUNCTION incSubitiPeriodo(da DATE, a DATE) RETURN NUMBER /* here's the second PLS-00539 error */
    IS incidenti NUMBER;
    BEGIN
    SELECT count(i. cod_incidente) INTO incidenti
    FROM incidente i , mezzo m
    WHERE SELF. cod_cliente = m.proprietario.cod_cliente AND m. num_targa = i.mezzo. num_targa AND i. responsabilita = 's' AND (i.data_inc BETWEEN da and a);
    RETURN (incidenti);
    END;
    MEMBER FUNCTION nomeCliente RETURN VARCHAR
    IS
    BEGIN
    RETURN TO_CHAR(cod_cliente);
    END;
    MEMBER FUNCTION tipoCliente RETURN VARCHAR
    IS
    BEGIN
    RETURN ('u');
    END;
    END;
    create TYPE t_cliente_pers UNDER t_cliente (
    persona REF t_persona,
    OVERRIDING MEMBER FUNCTION nomeCliente RETURN VARCHAR,
    OVERRIDING MEMBER FUNCTION tipoCliente RETURN VARCHAR
    ) NOT FINAL
    create or replace
    TYPE BODY t_cliente_pers AS
    OVERRIDING MEMBER FUNCTION nomeCliente RETURN VARCHAR
    IS nc VARCHAR(90);
    BEGIN
    SELECT concat(DEREF(SELF.persona).dati_anagrafici.nome, concat(' ',DEREF(SELF.persona).dati_anagrafici.cognome)) INTO nc
    FROM DUAL;
    RETURN (nc);
    END;
    OVERRIDING MEMBER FUNCTION tipoCliente RETURN VARCHAR
    IS
    BEGIN
    RETURN ('p');
    END;
    END;
    create TYPE t_cliente_soc UNDER t_cliente (
    societa t_societa,
    OVERRIDING MEMBER FUNCTION nomeCliente RETURN VARCHAR,
    OVERRIDING MEMBER FUNCTION tipoCliente RETURN VARCHAR
    ) NOT FINAL
    create or replace
    TYPE BODY t_cliente_soc AS
    OVERRIDING MEMBER FUNCTION nomeCliente RETURN VARCHAR
    IS
    BEGIN
    RETURN (societa.ragione_sociale.nome_soc);
    END;
    OVERRIDING MEMBER FUNCTION tipoCliente RETURN VARCHAR
    IS
    BEGIN
    RETURN ('s');
    END;
    END;
    /

    The declarations of functions incFattiPeriodo and incSubitiPeriodo differ between type specification and type body (the ones in the type body have formal parameters).

  • PLS-00306 Error

    Hi All,
    I am totally new to PL/SQL development. Sorry for any stupid doubts.
    I am trying to create a package which has a function with few in and one out parameters. When I try to compile the package, it throws me the following:
    : PLS-00306: wrong number or types of arguments in call to 'GET_COMBINATION_ID'.
    Below is my package:
    TYPE SegmentArray is table of varchar2(200) INDEX BY BINARY_INTEGER;
    create or replace
    PACKAGE BODY xx_fnd_flex_ext_pkg
    as
    FUNCTION xx_get_comb_id(v_app_short_name      IN VARCHAR2,
                   v_key_flex_code     IN VARCHAR2,
                   v_structure_number     IN NUMBER,
                   v_validation_date     IN DATE,
    v_n_segments IN NUMBER,
                   v_segments IN SegmentArray,
                   v_combination_id     OUT NUMBER,
    v_data_set IN NUMBER DEFAULT -1)
    RETURN VARCHAR2 IS
    temp BOOLEAN;
    ccid NUMBER;
    BEGIN
    temp := apps.fnd_flex_ext.get_combination_id(application_short_name => v_app_short_name,
    key_flex_code => v_key_flex_code,
    structure_number => v_structure_number,
    validation_date => v_validation_date,
    n_segments => v_n_segments,
    segments => v_segments,
    combination_id => ccid,
    data_set => v_data_set);
    v_combination_id := ccid;
    if(temp = true)
    then return 'TRUE';
    end if;
    if(temp = false)
    then return('FALSE');
    end if;
    END xx_get_comb_id;
    END xx_fnd_flex_ext_pkg;
    The apps.fnd.flex.get_combination_id and my custom function takes exactly the same parameters. But its failing somewhere. Pls help me on this.
    Thanks,
    Sreeram Kosaraju.

    Hi,
    The segments parameter of apps.fnd_flex_ext.get_combination_id seems to have a user-defined dataype SegmentArray. That datatype is probably owned by the apps schema, perhaps defined in the fnd_flex_ext package.
    Even if you find out how that datatype was defined, and you define one exactly like it in your own schema, they will be different datatypes.
    Without seeing the documentation or code for apps.fnd_flex_ext, I can't tell what you should be doing.
    It might be something as simple as using apps.fnd_flex_ext.SegmentArray (instead of your own SegmentArray) in all of your declarations.

  • Calling stored procedure from page process and PLS-00049 error?

    Good morning guys!
    I'm dealing with several problems this morning! The one that I need to deal with first is the following.
    I created the page process (see below: 1st code) in order to validate if all records where LNG_GEBIET matches have the status 3 or 4. If that is the case I want to call the procedure "set_status_arbeit_zu_gebiet". If amountrs and countstat do not match, then nothing is supposed to be done.
    The problem lies within the stored procedure itself. I receive a PLS-00049 bind variable error for :new.LNG_GEBIET.
    Can you please tell me what I forgot to declare in code 2 below???
    Thank you guys!
    The page process:
    Declare
      amountrs    number;
      countstat   number;
    begin
    SELECT COUNT(*) INTO amountrs FROM TBL_PUNKTDATEN where LNG_GEBIET = :P4_CNT_GEBIET;
    SELECT COUNT(*) INTO countstat FROM TBL_PUNKTDATEN where LNG_GEBIET = :P4_CNT_GEBIET and INT_STATUS = 3 or LNG_GEBIET = :P4_CNT_GEBIET and INT_STATUS = 4;
        IF amountrs = countstat THEN
         set_status_arbeit_zu_gebiet;
        ELSE
         dbms_output.put('nothing');
        END IF ;
    end;Code 2 with the true problem!
    CREATE OR REPLACE PROCEDURE set_status_arbeit_zu_gebiet
    IS
        cursor c2 is select LNG_GEBIET from TBL_ARBEIT_ZU_GEBIET where PNUM = 1114 and LNG_GEBIET=:new.LNG_GEBIET;
        v_c2  c2%ROWTYPE;
    BEGIN
       open c2;
    fetch c2 into v_c2;
    if c2%notfound then
            INSERT INTO TBL_ARBEIT_ZU_GEBIET
            LNG_GEBIET,
              LNG_ARBEITSSCHRITT,
              PNUM,
              INT_BEARBEITER,
              DATE_DATUM,
              GEPL_DATUM
            VALUES
            (:new.LNG_GEBIET,
             52,
             1114,
             895,
             sysdate,
             to_date('01.01.1990', 'DD.MM.YYYY')
            commit;
            close c2;
    END set_status_arbeit_zu_gebiet;One more question: Is it possible to integrate the first validation that calls my stored procedure into code 2?
    Thanks for you time!
    Sebastian

    The error is in following statement:
    INSERT INTO TBL_ARBEIT_ZU_GEBIET ( ... ) VALUES ( :new.LNG_GEBIET, ... );
    As the statement is part of a procedure and not trigger so it is not able to bind this variable with any value.
    As a resolution, pass this value to the procedure from the process and use it in the insert statement.
    The process will have following IF statement:_
    IF amountrs = countstat THEN
    set_status_arbeit_zu_gebiet *(:P4_CNT_GEBIET)*;
    ELSE
    dbms_output.put('nothing');
    END IF ;
    and the procedure will be as follows:_
    CREATE OR REPLACE PROCEDURE set_status_arbeit_zu_gebiet *(p_lng_gebit varchar2)*
    IS
    cursor c2 is select LNG_GEBIET from TBL_ARBEIT_ZU_GEBIET where PNUM = 1114 and LNG_GEBIET= --:new.LNG_GEBIET-- p_lng_gebit ;
    v_c2 c2%ROWTYPE;
    BEGIN
    INSERT INTO TBL_ARBEIT_ZU_GEBIET ( ... )
    VALUES
    ( --:new.LNG_GEBIET--  p_lng_gebit, ... );
    END set_status_arbeit_zu_gebiet;

  • My songs dont download properly when it comes up it shaded in grey and it says error anyone pls help, My songs dont download properly when it comes up it shaded in grey and it says error anyone pls help

    My songs dont download properly when it comes up it shaded in grey and it says error anyone pls help, My songs dont download properly when it comes up it shaded in grey and it says error anyone pls help
    Im on ipod 6.1.3 non jaillbroken
    and i have not bought songs from itunes store

    What is the wording of the error message?
    When you say download do yo mean:
    - directly downloading from iTunes?
    - Syncing to computer?

  • HT6001 After updated to iTunes 11.1.4 for windows vista , I was unable to open iTunes and it keep error message. My iphone unable to USB hotspot the internet to computer. Pls Help

    After updated to iTunes 11.1.4 for windows vista , I was unable to open iTunes and it keep error message. My iphone unable to USB hotspot the internet to computer. Pls Help

    Go to Control Panel > Add or Remove Programs (Win XP) or Programs and Features (later)
    Remove all of these items in the following order:
    iTunes
    Apple Software Update
    Apple Mobile Device Support (if this won't uninstall move on to the next item)
    Bonjour
    Apple Application Support
    Reboot, download iTunes, then reinstall, either using an account with administrative rights, or right-clicking the downloaded installer and selecting Run as Administrator.
    The uninstall and reinstall process will preserve your iTunes library and settings, but ideally you would back up the library and your other important personal documents and data on a regular basis. See this user tip for a suggested technique.
    Please note:
    Some users may need to follow all the steps in whichever of the following support documents applies to their system. These include some additional manual file and folder deletions not mentioned above.
    HT1925: Removing and Reinstalling iTunes for Windows XP
    HT1923: Removing and reinstalling iTunes for Windows Vista, Windows 7, or Windows 8
    tt2

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

    Hi All,
    I am trying to create a Queue and En-queue a message but I am getting error while en-queue a message as,
    "*ERROR at line 10:*
    *ORA-06550: line 10, column 3:*
    *PLS-00306: wrong number or types of arguments in call to 'ENQUEUE'*
    *ORA-06550: line 10, column 3:*
    *PL/SQL: Statement ignored*"
    I am using oracle 11g R2. Below is the script, user mthiiora1 has AQ ADMIN privilege,
    CREATE TYPE mthiiora1.mt_ora1_q_type1 AS OBJECT (message_id NUMBER,
    message_text VARCHAR2(4000));
    BEGIN
    -- Creating Queue Table
    DBMS_AQADM.CREATE_QUEUE_TABLE (queue_table => 'mt_ora1_q_type1_t1',
    queue_payload_type => 'mthiiora1.mt_ora1_q_type1');
    -- Creating Queue
    DBMS_AQADM.create_queue (queue_name => 'mt_ora1_que1',
    queue_table => 'mt_ora1_q_type1_t1');
    -- Starting Queue
    DBMS_AQADM.start_queue (queue_name => 'mt_ora1_que1',
    enqueue    => TRUE);
    END;
    DECLARE
    laq_queue_options         DBMS_AQ.ENQUEUE_OPTIONS_T;
    laq_message_properties    DBMS_AQ.MESSAGE_PROPERTIES_T;
    laq_message_id            RAW(32);
    laq_message               mthiiora1.mt_ora1_q_type1;
    BEGIN
    laq_message := mthiiora1.mt_ora1_q_type1(1, 'Message 1');
    DBMS_AQ.enqueue ( queue_name          => 'mt_ora1_que1',
    enqueue_options     => laq_queue_options,
    message_properties  => laq_message_properties,
    pay_load            => laq_message,
    msgid               => laq_message_id);
    COMMIT;
    END;
    Could you anyone please help me to resolve this issue?

    hi orawiss,
    Thank you. I went through this link before i post the question in this fourm. But the parameters of DBMS_AQ.enqueue is same as my code. But why am I still getting the error message?

  • Unable to generate the XML file through SQL script. getting error PLS-00306

    I am fetching the data from cursor and generating the xml output I am getting the below error.
    When I have checked the cursor query it is fetching the data in to single column.
    Input truncated to 1 characters
    Enter value for 7: EXEC FND_CONC_STAT.COLLECT;
    DBMS_LOB.append (tmp_file, r.core_xml);
    ERROR at line 95:
    ORA-06550: line 95, column 7:
    PLS-00306: wrong number or types of arguments in call to 'APPEND'
    ORA-06550: line 95, column 7:
    PL/SQL: Statement ignored

    Hi Alex,
    thanks for the responce..
    i have fixed the issue
    i have used XMLAttributes to get the value
    SELECT XMLELEMENT (
    NAME "TranACK",
    XMLAttributes ('1' as "TranNum",
    (select distinct to_char(SYSDATE,'yyyy-mm-dd')
    from DUAL) as "PrcDate"),
    XMLFOREST (
    a.PAYMENT_ID AS "PmtID"),
    XMLFOREST (
    a.ACK_TRANSACTION_RECEIVER AS "Name1"),
    XMLFOREST (
    to_char(a.VALUE_DATE,'yyyy-mm-dd') as "ValueDate" ),
    XMLFOREST (
    a.PAYMENT_AMOUNT AS "CurAmt"),
    XMLFOREST (
    a.CURRENCY_CODE AS "CurCode")
    ).getclobval ()
    AS line_xml
    FROM XXWAP_PAYMENT_LINE_TBL a
    where a.PAYMENT_BATCH_ID=P_batch_id;

  • 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

  • Error PLS-00306 during calling PL/SQL function from Java

    Hi all,
    I am facing a problem during call of oracle PL/SQL function from java using CallableStatement.
    I receive following error message.
    java.sql.SQLException: ORA-06550: line 1, column 13:
    PLS-00306: wrong number or types of arguments in call to 'EXPORT_HIST_ALARMS_FUNC'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    As per above error EXPORT_HIST_ALARMS_FUNC in oracle has this signature.
    CREATE OR REPLACE FUNCTION EXPORT_HIST_ALARMS_FUNC(startDateTime VARCHAR2, endDateTime VARCHAR2, meType VARCHAR2) RETURN VARCHAR2 IS
    END EXPORT_HIST_ALARMS_FUNC;
    Above function I have called following way in java.
    String sql = "begin ?:= EXPORT_HIST_ALARMS_FUNC(?, ?, ?); end;" ;
    CallableStatement cStatement = null;
    cStatement = connection.prepareCall(sql);
    cStatement.registerOutParameter(1,Types.VARCHAR);
    cStatement.setString(2,startDateTime);
    cStatement.setString(3,endDateTime);
    cStatement.setString(4,meType);
    cStatement.execute();
    msg = cStatement.getString(1);
    Actually above function requires three input parameters and one return parameter.
    During execution of above java code it throws SQLException and shows PLS-00306: wrong number or types of arguments in call to 'EXPORT_HIST_ALARMS_FUNC' error.
    I have run this function directly from oracle with three parameters and run successfully and finally it returns string.
    But I am unable to figure out why it doesn't run from above java code.
    Please help regarding this.
    Thanks.
    Regards,
    Shardul Banker

    Try this:
    String sql = "begin ?:= EXPORT_HIST_ALARMS_FUNC(?, ?, ?); end;" ;
    CallableStatement cStatement = null;
    cStatement = connection.prepareCall(sql);
    cStatement.registerOutParameter(1,Types.VARCHAR);
    cStatement.setString(1,startDateTime);
    cStatement.setString(2,endDateTime);
    cStatement.setString(3,meType);
    cStatement.execute();
    msg = cStatement.getString(1);Regards,
    Martijn Teigeler
    Edited by: mTeigeler on Oct 13, 2007 10:22 AM

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

    Hi,
    I have created a function :
    create or replace procedure Test11 AS
    x Test.Emp_No%Type;
    Begin
    select emp_no into x from Test where name = 'Sud';
    x := x + 1;
    update Test set emp_no = x where emp_no < 100;
    commit;
    end Test11;
    This has compiled successfully in PL/SQL Developer. Now, I have created an executable of this procedure in Front end - 11i. And then I have created a Program of this executable. Then I have added this program to a request group.
    Now that I am running this request and I getting this error in the log :
    ORACLE error 6550 in FDPSTP
    Cause: FDPSTP failed due to ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'TEST11'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    .

    Hi,
    Your procedure is a little confusing. By the way, this procedure has no parameters and I supose that maybe you are calling it with some parameter. Could you check this please?
    Tip: post your code inside tags (start and end tag are the same) to proper formatting :)
    Regards,
    Edited by: Walter Fernández on Dec 3, 2008 10:53 AM - Adding tip...                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • 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!!

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

    I have create a algorithm which The member function at the end, returns xc and yc.
    ERROR at line 9:
    ORA-06550: line 9, column 63:
    PLS-00306: wrong number or types of arguments in call to 'o'
    ORA-06550: line 9, column 2:
    PL/SQL: Statement ignored

    Guess your function has: RETURN NUMBER
    If so, the statement RETURN 'True' will give you exactly that error.
    Also:
    Return xc;
    Return yc;
    does not work as intended. The function will end by returning xc. (If it ever makes it that far)

  • FND_REQUEST.SUBMIT_REQUEST via forms erroring in CM with PLS-00306

    Hello,
    I have a form that needs to submit a custom concurrent program when a button is pressed on a form. The code is in the when-button-pressed trigger and is as follows:
    declare
         v_req_id NUMBER;
         v_project_name VARCHAR2(32);
         v_subject VARCHAR2(70);
         v_message VARCHAR2(240);
         v_email_from VARCHAR2(30):= 'PROJECT_EMAIL';
         v_email_to VARCHAR2(30):= 'BONNI_SMITH';
         v_yes_no VARCHAR2(1) := 'Y';
    begin
         select :TFN_PROJECT_DETAILS.project_num||' '||:tfn_project_details.project_desc
         into v_project_name
         from dual;
         select 'PROJECT '||:tfn_project_details.project_num||' NOTIFICATION'
         into v_subject
         from dual;
         select v_project_name||' project has been created in the project system'
         into v_message
         from dual;
         FND_MESSAGE.DEBUG('proj name: '||V_PROJECT_NAME);
         FND_MESSAGE.DEBUG('message: '||V_MESSAGE);
         FND_MESSAGE.DEBUG('subject: '||V_SUBJECT);
    v_req_id := FND_REQUEST.SUBMIT_REQUEST
    ('TALBOTS',
    'TFNSENDEMAIL',
    'TFN_PROJECT_DETAILS',
    FALSE,
    v_email_from,
    v_email_to,
    v_subject,
    v_message,
    v_yes_no,
         FND_MESSAGE.DEBUG(v_req_id);
    IF (v_req_id = 0) then
    fnd_message.retrieve;
    fnd_message.error;
    Raise Form_Trigger_Failure;
    ELSE
         FND_MESSAGE.SET_STRING('Email Request submitted. Request ID '|| v_req_id);
    fnd_message.show;
    :tfn_project_details.last_email_date := sysdate;
    APP_STANDARD.EVENT('KEY-COMMIT');
    END IF;
    end;
    This code gives me an error in the request log of: PLS-00306: wrong number or types of arguments in call to 'SEND_EMAIL'
    I have verified that the type of the arguments is correct, so I am assuming that it is upset over the number? I have recounted several times and come up with the 100 required. I have also changed the parameters from hard-coded to parameters and it has made no difference. I even put an 'x' in the last parameter to make sure that the entire string is being passed, and when I look in the request sable it is there in the table data as the 100th parm. I have made sure that the varaibles in the trigger match the lengths and types of the parameters in the CM program.
    I have practically the same trigger submitting a different CM job and it works perfectly. Both CM requests are custom host scripts.
    Can anyone offer help on this?

    I shortened the code and the error is:
    "could not be evaluated because of error ORA-00923: FROM keyword not found where expected"
    This isn't of much help to me.
    Edited by: user11970177 on Mar 4, 2011 7:06 AM

  • Enqueue and Dequeue of BLOB messages

    Hi all,
    Does anyone have any experience with enqueue and dequeue of BLOB messages? I have PDF files that I would like to send via aq. I can enqueue them, but not dequeue them. When I attempt to deque, I get the following error:
    ORA-25236: buffer too small for user data
    Here is my enqueue code:
    set serveroutput on size 1000000
    set timing on
    /* Enqueue to msg_queue: */
    DECLARE
       Enqueue_options     DBMS_AQ.enqueue_options_t;
       Message_properties  DBMS_AQ.message_properties_t;
       Message_handle      RAW(16);
       Message             blob;
         TmpMsg              blob := empty_blob;
         cnt                 number;
    BEGIN
       DBMS_AQ.ENQUEUE(queue_name => 'JOOSTENBERGVLAKTE',
       Enqueue_options            => enqueue_options,
       Message_properties         => message_properties,
       Payload                    => tmpmsg,
       Msgid                      => message_handle);
         select t.user_data into message from test_queue t where t.msgid = message_handle;
         select blob_content into tmpmsg from tbl;
         cnt := length(message) + 1;
         dbms_lob.erase(message, cnt);
         dbms_lob.trim(message, 0);
         dbms_lob.append(message, tmpmsg);
         dbms_output.put_line('Erased ' || cnt || ' characters');
         dbms_output.put_line('Message length ' || length(message));
       COMMIT;
    END;
    /And here is my deque code:
    set serveroutput on 1000000;
    declare
         l_options         dbms_aq.dequeue_options_t;
         l_properties      dbms_aq.message_properties_t;
         l_hnd             RAW(16);
         l_msg             blob := empty_blob;
    begin
         dbms_aq.dequeue(
              queue_name => 'JOOSTENBERGVLAKTE',
              dequeue_options => l_options,
              message_properties => l_properties,
              payload => l_msg,
              msgid => l_hnd
         commit;
    exception
         when others then
              rollback;
              raise;
    end;
    /

    Hi,
    I think you have the order of enqueueing and filling your blob in the wrong order. I understand why you do it, because inserting a blob in the table you could do that in this way. But I think that you should fill and close your blob before enqueueing it.
    Try something like:
    l_attachment blob;-- := :p_attachment;
    begin
    dbms_lob.createtemporary(l_attachment, false);
    dbms_lob.write( lob_loc => l_attachment
    , amount => length(:p_attachment)
    , offset => 1
    , buffer => utl_raw.cast_to_raw(:p_attachment));
    Another small remark is that I see you doing a commit right after the enqueue-dequeue. In your enqueu example it seems to make sense because you try to fill the blob afterwards. But you could also use the enqueue-dequeue option "visibility" and set that on dbms_aq.immediate. Then you don't have to do a commit. This is handy for enqueueing messages with out affecting your transaction.
    Regards,
    Martien

Maybe you are looking for