ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments

Hi all
Here is the error:
ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments
The following code generates the error:
create or replace PROCEDURE AMENDNUMBER_UPDATE
(
SHIP_NUMBER IN VARCHAR2,
AMEND_NO ON SYS_REFCURSOR)
AS
BEGIN
UPDATE CSPS_SHIPMENT_INFO_TL
SET AMENDMENT_NO =
(SELECT AMENDMENT_NO + 1
OF CSPS_SHIPMENT_INFO_TL
WHERE SHIPMENT_NUMBER = SHIP_NUMBER
)
WHERE SHIPMENT_NUMBER = SHIP_NUMBER;

AMEND_NO OPEN FOR SELECT AMENDMENT_NO FROM CSPS_SHIPMENT_INFO_TL WHERE SHIPMENT_NUMBER = SHIP_NUMBER;

-VALIDATION;
END AMENDNUMBER_UPDATE;

now when I try to run the under statement I get the above error:
exec amendnumber_update (ship_number);


Please suggest how to manage...

Hello

TCSBPMUSER wrote:
Hi all
Here is the error:
ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments

It's one of these error messages that actually means what he says.

The following code generates the error:
create or replace PROCEDURE AMENDNUMBER_UPDATE
(
SHIP_NUMBER IN VARCHAR2,
AMEND_NO ON SYS_REFCURSOR)
AS...

now when I try to run the under statement I get the above error:
exec amendnumber_update (ship_number);

The procedure requires 2 arguments.
You try to call with only 1 argument. It's the wrong number of arguments.

To call the procedure from SQL * Plus, you can do something like this:

VARIABLE   rc  REFCURSOR

EXEC  amendnumber_update (123, :rc);

The 1st argument is an argument IN, so you can pass any kind of digital expression. (I used a literal above.)
The 2nd argument is an OUT argument, so you must pass a variable. (I used a variable link above.)

Tags: Database

Similar Questions

  • ORA-06550: line 21, column 5: PLS-00306: wrong number or types of arguments

    Dear Sir

    can someone help what is the problem?
    I get the error message:
    ORA-06550: line 21, column 5: PLS-00306: wrong number or types of arguments in the call to 'STRONG_PASSWORD_VALIDATION' ORA-06550: line 21, column 5: PL/SQL: statement ignored

    code is:
    ---
    DECLARE
    l_username varchar2 (100);
    l_password varchar2 (100);
    l_old_password varchar2 (100);
    l_workspace_name varchar2 (30);
    l_min_length_err boolean;
    l_new_differs_by_err boolean;
    l_one_alpha_err boolean;
    l_one_numeric_err boolean;
    l_one_punctuation_err boolean;
    l_one_upper_err boolean;
    l_one_lower_err boolean;
    l_not_like_username_err boolean;
    l_not_like_workspace_name_err boolean;
    l_not_like_words_err boolean;
    BEGIN
    l_username: =: P29_CURR_USER;
    l_password: =: P29_NEW_PW;
    l_old_password: =: P29_PW;
    l_workspace_name: = APEX_UTIL. GET_DEFAULT_SCHEMA;
    APEX_UTIL. () STRONG_PASSWORD_VALIDATION
    p_username = > l_username,.
    p_password = > l_password,
    p_old_password = > l_old_password,
    p_workspace_name = > l_workspace_name,
    p_use_strong_rules = > false,
    p_min_length_err = > l_min_length_err,
    p_new_differs_by_err = > l_new_differs_by_err,
    p_one_alpha_err = > l_one_alpha_err,
    p_one_numeric_err = > l_one_numeric_err,
    p_one_punctuation_err = > l_one_punctuation_err,
    p_one_upper_err = > l_one_upper_err,
    p_one_lower_err = > l_one_lower_err,
    p_not_like_username_err = > l_not_like_username_err,
    p_not_like_workspace_name_err = > l_not_like_workspace_name_err,
    p_not_like_words_err = > l_not_like_words_err
    );

    IF l_min_length_err THEN
    return ('Kennwort ist zu kurz');
    END IF;

    IF l_new_differs_by_err THEN
    return ("' muss sich vom alten Kennwort unterscheiden Kennwort");
    END IF;

    IF l_one_alpha_err THEN
    return ('wenigstens einen letter included muss Kennwort');
    END IF;

    IF l_one_numeric_err THEN
    return ('wenigstens eine Ziffer included muss Kennwort');
    END IF;

    IF l_one_punctuation_err THEN
    return ('wenigstens ein Sonderzeichen included muss Kennwort');
    END IF;

    IF l_one_lower_err THEN
    return ('wenigstens einen Kleinbuchstaben included muss Kennwort');
    END IF;

    IF l_one_upper_err THEN
    return ('wenigstens einen Grossbuchstaben included muss Kennwort');
    END IF;

    IF l_not_like_username_err THEN
    return ('Kennwort darf nicht den included Nick');
    END IF;

    IF l_not_like_workspace_name_err THEN
    return ('Kennwort darf nicht den Namen-Workspace included');
    END IF;

    IF l_not_like_words_err THEN
    Return ("' contains unerlaubten term Kennwort") End Function
    END IF;
    Returns a null value.
    END;
    ---
    Any help is welcome.
    Kind regards
    Lorenz

    Look in your version of apex_util. Your code certainly doesn't look like using STRONG_PASSWORD_VALIDATION, which has very different parameters.

    My version (4.0) of STRONG_PASSWORD_CHECK has 16 parameters, your code has 15.

  • ORA-06550: line 8, column 21: PLS-00306: wrong number or types of arguments

    Hello

    I have a form page that inserts rows into a table by using a custom plsql which is defined through the application process. the process is shown as:

    DECLARE

    v_loop NUMBER: = trunc(:P43_SEG_SCH_DEP_DT2) - trunc(:P43_SEG_SCH_DEP_DT);
    date of T_DATE;
    BEGIN

    FOR v_LoopCounter IN 0.v_loop LOOP
    T_DATE: = trunc(:P43_SEG_SCH_DEP_DT) + v_LoopCounter * day interval '1';
    INSERT INTO slf_segment (id,
    seg_sch_dep_dt,
    dep_port,
    arr_port,
    BBLF,
    bslf)
    VALUES (NULL, T_DATE,: P43_DEP_PORT,: P43_ARR_PORT,: P43_BBLF,: P43_BSLF);
    END LOOP;
    commit;
    END;

    Simply, there are two dates and for loop runs for many times that the difference between the two days. In each race, it inserts a line that adds 1 day to the start date.
    I tested the code in pl/sql developer and it works perfectly. The table is created as follows:

    create the table SLF_SEGMENT
    (
    Identification NUMBER not null,
    DATE OF SEG_SCH_DEP_DT,
    DEP_PORT VARCHAR2 (30),
    ARR_PORT VARCHAR2 (30),
    NUMBER OF BBLF,
    NUMBER OF BSLF
    )

    And I got the error that is the subject of my subject. Any help?

    .

    Edited by: fac586 13-Aug-2011 10:19

    Jivelicate

  • column of username in dba_users PLS-00306: wrong number or types of arguments

    Can someone please help me understand what is happening here? I need to insert items in schemas a little, but I can't get the column username to work for some reason any.

    SQL > start
    2 for v_username looping (select username from dba_users)
    3 dbms_output.put_line (v_username);
    4 end of loop;
    5 end;
    6.
    dbms_output.put_line (v_username);
    *
    ERROR at line 3:
    ORA-06550: line 3, column 1:
    PLS-00306: wrong number or types of arguments in the call to "PUT_LINE '.
    ORA-06550: line 3, column 1:
    PL/SQL: Statement ignored


    SQL > dba_users desc;
    Name Null? Type
    ----------------------------------------- -------- ----------------------------
    USER NAME NOT NULL VARCHAR2 (30)
    USER_ID NOT NULL NUMBER
    PASSWORD VARCHAR2 (30)
    ACCOUNT_STATUS NOT NULL VARCHAR2 (32)
    DATE OF LOCK_DATE
    EXPIRY_DATE DATE
    USER_USERS NOT NULL VARCHAR2 (30)
    TEMPORARY_TABLESPACE NOT NULL VARCHAR2 (30)
    CREATION DATE NOT NULL
    PROFILE NON-NULL VARCHAR2 (30)
    INITIAL_RSRC_CONSUMER_GROUP VARCHAR2 (30)
    EXTERNAL_NAME VARCHAR2 (4000)

    SQL >

    >
    for v_username in a loop (select username from dba_users)
    >
    v_username in the loop is a CURSOR that represents the WHOLE folder.

    If you need to access the columns in the record using the dot notation. It works for me.

     declare
     v_username varchar2(30);
     begin
     for v_username in (select username from dba_users) loop
     dbms_output.put_line(v_username.username);
     end loop;
     end;
    
    SCOTT
    . . .
    
  • PLS-00306: wrong number or types of arguments in the call to ' |'

    Hello

    SQL> select * from v$version
      2  /
    
    BANNER
    ----------------------------------------------------------------
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Prod
    PL/SQL Release 10.2.0.1.0 - Production
    CORE    10.2.0.1.0      Production
    TNS for 32-bit Windows: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    

    Code

    DECLARE
    TYPE SARR IS TABLE OF VARCHAR2(8);
    l_tempdate SARR;
    l_temptable VARCHAR2(30) := 'TBL_EDATE';
    BEGIN
    EXECUTE IMMEDIATE ' SELECT FORMATDATE  BULK COLLECT INTO ' || l_tempdate || ' FROM  ' || l_temptable;
    END;
    /
    

    Error

    ERROR at line 6:
    ORA-06550: line 6, column 19:
    PLS-00306: wrong number or types of arguments in call to '||'
    ORA-06550: line 6, column 1:
    PL/SQL: Statement ignored
    

    TABLE (it will create dynamically)

    CREATE TABLE TBL_EDATE
    (
      FORMATDATE       VARCHAR2(8 BYTE),
      ORDERFORMATDATE  NUMBER
    )
    

    Insert Scripts

    Insert into TBL_EDATE   (FORMATDATE, ORDERFORMATDATE) Values   ('H2-2012', 2);
    Insert into TBL_EDATE   (FORMATDATE, ORDERFORMATDATE) Values   ('H1-2012', 1);
    
    

    Thank you

    Well, you asked?

    SQL > declare

    2 type sarr is table of the varchar2 (8);

    3 l_tempdate sarr;

    4 l_temptable varchar2 (30);

    5 str varchar2 (100);

    6 start

    7 - l_temptable: = get_temp_table_name (some arg); -logical, you must be knowing

    8 l_temptable: = "TBL_EDATE"; -Suspected function returned this value

    9 str: = ' Select format of ' | l_temptable | » ';

    10 run immediately str bulk collect into l_tempdate;

    11 dbms_output.put_line ('count' | l_tempdate.) (Count);

    12 end;

    13.

    County 2

    PL/SQL procedure successfully completed.

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

    We have the code in production and testing. the dbs, the servers are the same configuration. And two codes are the same (checked).

    Now all of a sudden the code on production for lack of sinus yesterday afternoon:

    BEGIN REQUEST_API. DBSS_process_FUDS; END;

    *
    ERROR on line 1:
    ORA-06550: line 1, column 93:
    PLS-00306: wrong number or types of arguments in the call to 'PROCESS_FUDS '.
    ORA-06550: line 1, column 93:
    PL/SQL: Statement ignored
    ORA-06512: at "SYS." Dbms_job", line 82
    ORA-06512: at "SYS." Dbms_job", line 140
    ORA-06512: at "ER. REQUEST_API', line 1190
    ORA-06512: at line 1

    Just with the test, it still works OK.

    Any idea? How can watch us?

    Thank you very much!

    The code can be the same (but you're not presenting the we a, then there's going to have to trust you on this), but what about data?
    And: are SQL * more guests of the same version as well?

    PLS-00306: wrong number or types of arguments in the call to 'string. '

    Cause: This error occurs when the named subprogram call cannot be matched to any statement for this subprogram name. Routine name can be spelled, a parameter can have the wrong data type, the statement may be defective or the statement may be
    placed correctly in the block structure. For example, this error occurs if the built-in square root SQRT function is called with a misspelled name or a parameter of the wrong data type.

    Action: Check the spelling and declaration of the name of routine. Also confirm that his appeal is correct, its parameters are of the right type of data, and, if it is not a built-in, that his statement is placed correctly in the block structure.

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

    now I'm on oracle10g xe, I get the following error

    create or replace procedure proc_name (slno_in in number,
    name_out out varchar2, fee_out certain number)
    is
    v_Name student.name%type;
    v_fee student.fee%type;
    Start
    Select name, cool in v_name, v_fee of
    student where slno = slno_in;
    name_out: = v_name;
    fee_out: = v_fee;
    end proc_ref;

    Created procedure.

    SQL > exec proc_name (1);
    BEGIN proc_ref (1); END;

    *
    ERROR on line 1:
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in the call to 'PROC_REF '.
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored





    Please help me
    DECLARE
     p_name VARCHAR2(50);
     p_fee NUMBER;
    BEGIN
     proc_name(1,p_name,p_fee);
     DBMS_OUTPUT.PUT_LINE(p_name||'--'||p_fee);
    END;
    
  • Error: PLS-00306: wrong number or types of arguments

    Hello

    I created a function:

    create or replace procedure AS Test11
    x Test.Emp_No%Type;
    Begin
    Select emp_no in x from Test whose name = 'South '.
    x: = x + 1;
    Update Test set emp_no = x where emp_no < 100;
    commit;
    end Test11;

    It has compiled with success in PL/SQL Developer. Now, I created an executable of this procedure in front-end - 11i. And then I created a program of this executable. Then I added this program to a group of application.

    Now that I run this query and I get this error in the log:

    Error ORACLE 6550 in FDPSTP

    Cause: FDPSTP failed due to the ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in the call to 'TEST11 '.
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    .

    Hello
    Whenever you save a function, or a PL/SQL procedure as a simultaneous program to apps, you must
    to add two parameters of type varchar2 (errbuf and retcode) Moreover to your settings.
    If you change procedure as follows:

    create or replace procedure Test11(errbuf   out varchar2,
                                       retcode out varchar2) 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;
    

    Published by: Anthony Alix on December 3, 2008 05:20

    Published by: Anthony Alix on December 3, 2008 05:25

    Published by: Anthony Alix on December 3, 2008 05:35

  • PLS-00306: wrong number or types of arguments in the call to 'XXC_AMOUNT' ORA-06550

    Hi all

    CREATE OR replace PROCEDURE Xxc_amount (v_item_id IN NUMBER,

                                             v_amount  OUT NUMBER,

                                             v_size    OUT NUMBER)

    IS

      v_size   NUMBER := NULL;

    v_amount NOMBRE;

    START

        BEGIN

    CHOOSE conversion_rate

            INTO   v_size

    FROM mtl_uom_class_conversions

            WHERE  inventory_item_id = v_item_id -- 2289;

            v_amount := Nvl (Trunc (v_size), 0);

    -RETURN (cp_cartons);

        EXCEPTION

            WHEN OTHERS THEN

              v_size := 0;

              dbms_output . Put_line ()' Error getting Item Id:'| V_ITEM_ID );

        END ;

    dbms_output. Put_line ('Qty-->' || v_amount );

    dbms_output. Put_line ('Qty1-->'|| v_size );

    END ;

    DECLARE

        amount NUMBER;

        v_size NUMBER;

    START

        Xxc_amount (2289, amount, v_size);

    dbms_output. Put_line (amount || '--' || v_size );

    END ;

    ORA-06550: line 5, column 5:

    PLS-00306: wrong number or types of arguments in the call to 'XXC_AMOUNT '.

    ORA-06550: line 5, column 5:

    PL/SQL: Statement ignored

    Thank you

    Post edited by: 994122 changed the name of the procedure to Xxc_amount Xxc_amount1

    Simply remove the declarations of the v_size and v_amount and it should work.

    The following text compiles and works for me when I call:

    CREATE OR replace PROCEDURE Xxc_amount (v_item_id IN NUMBER,
                                            v_amount  OUT NUMBER,
                                            v_size    OUT NUMBER)
    IS
    BEGIN
        BEGIN
            SELECT conversion_rate
            INTO  v_size
            FROM  mtl_uom_class_conversions
            WHERE  inventory_item_id = v_item_id; -- 2289;
            v_amount := Nvl (Trunc (v_size), 0);
        --RETURN (cp_cartons);
        EXCEPTION
            WHEN OTHERS THEN
              v_size := 0;
              dbms_output.Put_line ('Error in Getting for Item Id :'|| v_item_id);
        END;
        dbms_output.Put_line ('Qty-->' || v_amount);
        dbms_output.Put_line ('Qty1-->'|| v_size);
    END;
    
    DECLARE
        amount NUMBER;
        v_size NUMBER;
    BEGIN
        Xxc_amount (2289, amount, v_size);
        dbms_output.Put_line (amount || '--' || v_size);
    END;
    
  • ORA-06550, PLS-00306: wrong number or types of arguments in the call to ' |'

    Hi all

    Please help me about this error, if I comment the threshold (in the color of the thickness)

    ERROR on line 19:

    ORA-06550: line 19, column 25:

    PLS-00306: wrong number or types of arguments in the call to ' |'

    ORA-06550: line 19, column 3:

    PL/SQL: Statement ignored

    DECLARE

        TYPE nametable IS TABLE OF CHAR(10) INDEX BY BINARY_INTEGER;

        vname NAMETABLE

        CURSOR cf

        IS

          SELECT ename

            FROM emp;

        i     NUMBER;

    START

        OPEN cf;

        i := 1;

        LOOP

            FETCH cf INTO Vname (i);

            EXIT WHEN cf%NOTFOUND;

            i := i + 1;

        END LOOP;

        CLOSE cf;

    dbms_output. Put_line ('Name is ' || VNAME );

        FOR n IN 1.. VNAME . County LOOP

    dbms_output. Put_line ('Name is ' || VNAME (n));

        END LOOP;

    END ;


    Thank you

    VNAME is an associative array. You can not use in DBMS_OUTPUT. Put_line as such. You need to loop through what you did in the code after the DBMS_OUTPUT and print each element of the array individually.

  • ApexExport 06550 PLS-00306: wrong number or types of arguments

    My work of ApexExort was running great until about a month and I can't pinpoint the problem.  If I run it in production, I get the following error.  However if I run it on my localhost even exact script works very well.

    Exception in thread "main" java.sql.SQLException: ORA-06550: line 2, column 12:

    PLS-00306: wrong number or types of arguments in the call to 'EXPORT_APPLICATION_TO_CLOB '.

    ORA-06550: line 2, column 5:

    Set ORACLE_HOME=C:\Oracle\product\11.2.0\dbhome_1

    set CLASSPATH = % CLASSPATH statement; \;%O RACLE_HOME%\jdbc\lib\ojdbc5.jar;%apexExportJavaDir%

    set PATH = % PATH %; \;%O RACLE_HOME%\Bin

    JAVAHOME value = C:\Program Files\Java\jdk1.8.0_45

    Set startRunLocation = \\mgasan2\hdrive\ATS_Working\Scott_Working\PROD_SCRIPTS\APEX_APP_BKUP

    CD C:\apex_4.2\utilities

    All applications to export REM

    Java oracle.apex.APEXExport - db %oracleHost%:%oraclePort%/%OracleServiceName%-utilisateur % oracleUser %-% oracleSystemPass %-forum password




    < gphmh >

    Thanks for your suggestion of Kiran, but I understood what my problem was.  The APEX version in our database is older: 4.1.1.00.23 and I have been using a version 4.2 utilities apex when I should have used the C:\apex_4.1.1_en\apex\utilities

    CD C:\apex_4.2\utilities

    C:\apex_4.1.1_en\apex\utilities


    For the record, here's what worked for me...


    Set apexExportJavaDir=C:\apex_4.1.1_en\apex\utilities

    Set apexHtmlFileName = apex_info.html

    BackupLocation = c:\PROD_SCRIPTS\APEX_APP_BKUP\OUTPUT\TEST set

    Set ORACLE_HOME=C:\Oracle\product\11.2.0\dbhome_1

    set CLASSPATH = % CLASSPATH statement; \;%O RACLE_HOME%\jdbc\lib\ojdbc5.jar;%apexExportJavaDir%

    set PATH = % PATH %; \; C:\Program Files (x 86) \Java\jre7\bin

    Set startRunLocation = c:\PROD_SCRIPTS\APEX_APP_BKUP

    FIXED % apexExportJavaDir %

    Java oracle.apex.APEXExport - db %oracleHost%:1521/%OracleServiceName%-utilisateur % oracleUser %-% oracleSystemPass %-forum password

  • Nested Tables: PLS-00306: wrong number or types of arguments

    Hello

    I created a package for updating of wages for a list of the empnos passed as parameter inside below is the package code:

    CREATE or REPLACE PACKAGE method

    AS

    type emp_list IS TABLE OF emp.empno%type;

    PROCEDURE add_sal (empnos emp_list);

    END method;

    /

    CREATE or REPLACE PACKAGE body method

    AS

    PROCEDURE add_sal (empnos emp_list)

    AS

    BEGIN

    ForAll I IN 1... empnos. Count

    UPDATE emp SET sal = sal plus 100 WHERE empno is empnos (i);

    END add_sal;

    END method;

    /

    When I try to call the procedure to aid under block it works fine:

    DECLARE

    empnos emp_info.emp_list: = emp_info.emp_list (1111,1112);

    BEGIN

    emp_info.add_sal (empnos);

    END;

    /

    But when I try to create the same as type I created in the package and try to pass to the procedure, the block fails with the error:

    DECLARE

    type emp_list IS TABLE OF emp.empno%type;

    empnos emp_list;

    BEGIN

    empnos: = emp_list (1111,1112);

    emp_info.add_sal (empnos);

    END;

    /

    Error report-

    ORA-06550: line 8, column 3:

    PLS-00306: wrong number or types of arguments in the call to 'ADD_SAL '.

    Can someone please help me understand why we see this error?

    With the help of: Windows 8.1

    Database Oracle 12 c Enterprise Edition Release 12.1.0.1.0 - 64 bit Production

    PL/SQL Release 12.1.0.1.0 - Production

    "CORE 12.1.0.1.0 Production."

    AMT for 64-bit Windows: Version 12.1.0.1.0 - Production

    NLSRTL Version 12.1.0.1.0 - Production

    But when I try to create the same as type I created in the package and try to pass to the procedure, the block fails with the error:

    No - it is NOT of the same type. One is the type of package and this news isn't the type of packet.

    The fact that they have the same projection or a set of attributes is obsolete.

    See the Oracle documentation

    http://docs.Oracle.com/CD/B28359_01/AppDev.111/b28370/Collections.htm#BEIEADAA

    You can assign values to all fields at the same time that if you assign a record to another record with the same data type. With fields that match exactly isn't enough, as shown in example 5-48.

    Example 5-48 assigning all the fields of a record in a statement

    DECLARE
    -Two declarations of the same types.
    TYPE DeptRec1 IS MADE
    (dept_num NUMBER (2), dept_name VARCHAR2 (14));
    TYPE DeptRec2 IS MADE
    (dept_num NUMBER (2), dept_name VARCHAR2 (14));
    dept1_info DeptRec1;
    dept2_info DeptRec2;
    dept3_info DeptRec2;
    BEGIN
    -Is not allowed; different types of data,
    -even if the fields are the same.
    -dept1_info: = dept2_info;
    -This assignment is OK because the files have the same type.
    dept2_info: = dept3_info;
    END;
    /

  • PLS-00306: wrong number or types of arguments in the call to 'UPDATE_ORDER_NUMBER_SEQUENCE '.

    Hi Please help me solve the error given by this procedure

    TEXT

    --------------------------------------------------------------------------------

    PROCEDURE UPDATE_ORDER_NUMBER_SEQUENCE)

    sequenceName IN VARCHAR2,

    Inc. in full)

    AS

    stmt VARCHAR2 (2000);

    number of l_n;

    Start

    BEGIN

    -change the increment to Inc.

    stmt: = 'ALTER SEQUENCE | sequenceName | ' INCREMENT ' |

    Inc.;

    TEXT

    --------------------------------------------------------------------------------

    dbms_output.put_line (' execution "' | stmt |) '''');

    EXECUTE IMMEDIATE stmt;

    -Read the following value

    stmt: = "SELECT" | sequenceName | '. DOUBLE NEXTVAL ';

    dbms_output.put_line (' execution "' | stmt |) '''');

    EXECUTE IMMEDIATE stmt in l_n;

    -change the increment of 1

    stmt: = 'ALTER SEQUENCE | sequenceName | ' INCREMENT OF 1';

    dbms_output.put_line (' execution "' | stmt |) '''');

    EXECUTE IMMEDIATE stmt;

    EXCEPTION

    TEXT

    --------------------------------------------------------------------------------

    While some OTHER THEN dbms_output.put_line (SQLERRM);

    END;

    end UPDATE_ORDER_NUMBER_SEQUENCE;

    following error please help me solve this error

    ERROR on line 1:

    ORA-06550: line 1, column 7:

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

    'UPDATE_ORDER_NUMBER_SEQUENCE '.

    ORA-06550: line 1, column 7:

    PL/SQL: Statement ignored

    Well, the error message is pretty self-explanatory, isn't it? What you use

    to call this procedure actually raises this error.

    However, you have not posted the SQL that actually calls this procedure

    so please post that.

    That said, the whole procedure seems wrong - what business requirement is there for

    edit sequences? This isn't normally how they should be used.

  • Iterating through a collection of cursor type give PLS-00306: wrong number or types of arguments in the call to "PUT_LINE '.

    I wrote the following anonymous block. He has a slider ""cur_total_tckt "who choose 6 columns."  A nested table 'total_tckt_colcn' is declared of type ""cur_total_tckt "."  In the dbms_output.put_line I want to print each item in my collection. It gives me the following error:

    PLS-00306: wrong number or types of arguments in the call to "PUT_LINE '.

    ORA-06550: line 29, column 2:

    PL/SQL: Statement ignored

    06550 00000 - "line %s, column % s:\n%s".

    I want to print all 6 columns of an element for 366 these elements.

    ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    DECLARE
    CURSOR cur_total_tckt    
      is
      select t.ticket_id ticket_id, t.created_date created_date, t.created_by created_by, t.ticket_status ticket_status,
      t.last_changed last_changed, h.created_date closed_date
      from n01.cc_ticket_info t
      inner join n01.cc_ticket_status_history h
      on (t.ticket_id = h.ticket_id)
      where t.last_changed >= '6/28/2012 17:28:59' and t.last_changed < (sysdate + interval '1' day);

    type total_tckt_colcn
    is
      TABLE OF cur_total_tckt%rowtype;
      total_tckt_col total_tckt_colcn;
      total_coach_col total_tckt_colcn;
    begin
    total_tckt_col := total_tckt_colcn ();
    total_coach_col := total_tckt_colcn ();
      OPEN cur_total_tckt;
      loop
      fetch cur_total_tckt bulk collect into total_tckt_col limit 100;

      dbms_output.put_line(total_tckt_col.last);

      FOR i IN total_tckt_col.first..total_tckt_col.last
      loop

      -- dbms_output.put_line(total_tckt_col(i).ticket_id);          -- this line works
      dbms_output.put_line(total_tckt_col(i));                       -- this line gives error

      END LOOP;

      exit
      WHEN (cur_total_tckt%NOTFOUND);

      END LOOP ;
      CLOSE cur_total_tckt; 




    end;

    making reference to an element differs from the reference to a field in the record that is part of the collection.

    'dbms_output.put_line (total_tckt_col (i))' works if there is only a single element.

    will not work if this element has subcomponents. in your case it has subcomponents as fields in a record.

  • PLS-00306: wrong number or types of arguments in call to... my cursor

    Hi all

    I try to use the same cursor for an explicit cursor and a cursor for loop. Can I do this? I get the error:
    PLS-00306: wrong number or types of arguments in call to
             'CUR_DEPT'
    This is my code:
         PROCEDURE LIST_DEPT_PRODUCTS (dept_name VARCHAR2)
         IS
          i_1 CHAR(1):=' ';
          i_2 CHAR(2):='  ';
          i_3 CHAR(3):='   ';
          i_4 CHAR(4):='    ';
          lv_deptid bb_department.idDepartment%TYPE;
          lv_deptname bb_department.DeptName%TYPE;
          lv_deptdesc bb_department.DeptDesc%TYPE;
          CURSOR cur_dept (dept VARCHAR2) IS
          SELECT d.DeptName, d.DeptDesc, d.idDepartment
          INTO lv_deptname, lv_deptdesc, lv_deptid
          FROM bb_department d 
          WHERE DeptName = dept
          ORDER BY DeptName;
           CURSOR cur_prod IS
           SELECT p.ProductName, p.Description, p.Price, p.SaleStart, p.SaleEnd
           FROM bb_product p 
           WHERE idDepartment = lv_deptid
           ORDER BY ProductName;
         BEGIN
         IF (dept_name = 'Coffee') THEN
           OPEN cur_dept(dept_name);
            LOOP
              FETCH cur_dept INTO lv_deptname, lv_deptdesc, lv_deptid;
              EXIT WHEN cur_dept%notfound;
                   DBMS_OUTPUT.PUT_LINE(lv_deptname);
                   DBMS_OUTPUT.PUT_LINE(i_1||lv_deptdesc);
                   DBMS_OUTPUT.PUT_LINE(chr(1));
              FOR l_prod in cur_prod LOOP
                   DBMS_OUTPUT.PUT_LINE(i_2||l_prod.ProductName);
                   DBMS_OUTPUT.PUT_LINE(i_3||SUBSTR(l_prod.Description,1,70));
                   DBMS_OUTPUT.PUT_LINE(i_4||'Price -  '||FORMAT_DOLLARS(l_prod.Price));
                   IF l_prod.SaleStart IS NOT NULL THEN
                   DBMS_OUTPUT.PUT_LINE(i_4||'Sale runs from '||FORMAT_DATE(l_prod.SaleStart)||' until '||FORMAT_DATE(l_prod.SaleEnd));
                   END IF;
                   DBMS_OUTPUT.PUT_LINE(chr(1));
            END LOOP;
           END LOOP;
           CLOSE cur_dept;
         ELSIF (dept_name = 'All') THEN
             FOR l_dept in cur_dept LOOP
                   DBMS_OUTPUT.PUT_LINE(l_dept.DeptName);
                   DBMS_OUTPUT.PUT_LINE(i_1||l_dept.DeptDesc);
                   DBMS_OUTPUT.PUT_LINE(chr(1));
              FOR l_prod in cur_prod LOOP
                   DBMS_OUTPUT.PUT_LINE(i_2||l_prod.ProductName);
                   DBMS_OUTPUT.PUT_LINE(i_3||SUBSTR(l_prod.Description,1,70));
                   DBMS_OUTPUT.PUT_LINE(i_4||'Price -  '||FORMAT_DOLLARS(l_prod.Price));
                   IF l_prod.SaleStart IS NOT NULL THEN
                   DBMS_OUTPUT.PUT_LINE(i_4||'Sale runs from '||FORMAT_DATE(l_prod.SaleStart)||' until '||FORMAT_DATE(l_prod.SaleEnd));
                   END IF;
                   DBMS_OUTPUT.PUT_LINE(chr(1));
            END LOOP;
           END LOOP;
           CLOSE cur_dept;
         ELSE
          DBMS_OUTPUT.PUT_LINE('No department found with name '||dept_name);
         END IF;
         END LIST_DEPT_PRODUCTS;
    Oh also if someone could tell me how to format DBMS_OUTPUT. Put_line so that I could dash in some lines that would be great. Did not work as I did.

    Thank you!

    Published by: user10915730 on April 18, 2009 07:48

    Published by: user10915730 on April 18, 2009 07:48

    Hello

    In the ELSIF clause, you must open the cursor. For dash maybe you can use:

    Connected to Oracle Database 10g Express Edition Release 10.2.0.1.0
    Connected as hr
    
    SQL>
    SQL> SET SERVEROUTPUT ON
    SQL> DECLARE
      2
      3     FUNCTION fnc_indent(nTimes IN NUMBER) RETURN VARCHAR2 IS
      4        v_result VARCHAR2(4000);
      5        c_tab CONSTANT VARCHAR2(1) := chr(9);
      6     BEGIN
      7        FOR i IN 1 .. nTimes LOOP
      8           v_result := v_result || c_tab;
      9        END LOOP;
     10        RETURN v_result;
     11     END fnc_indent;
     12
     13  BEGIN
     14     DBMS_OUTPUT.put_line(fnc_indent(1) || 'hello');
     15     DBMS_OUTPUT.put_line(fnc_indent(2) || 'hello');
     16     DBMS_OUTPUT.put_line(fnc_indent(3) || 'hello');
     17  END;
     18  /
    
         hello
              hello
                   hello
    
    PL/SQL procedure successfully completed
    
    SQL> 
    

    Kind regards

Maybe you are looking for

  • Designation of the owner/group MySql server

    QUESTION: I recently discovered that the MySql server is the owner of all my directories root (see image).  I don't remember having done anything to cause such a transformation will take place.  Until I upgraded to El Capitan, this had never been the

  • Firefox will not reinstall on my computor

    Firefox did an overnite update, and after that I couldn't on the internet using Firefox. I deleted and tried to reinstall it, but it keeps just downloading. Sometimes I get an error message of not having mozglue.dll.

  • Satellite Pro S300 - USB no longer works

    HelloI have a 6 month laptop Satellite Pro S300-100 and running Vista 32 bit. He got 4 USB slots, 1 handset that works on the left side and 3 USB2 connectors right side and these 3 suddenly stopped working. I tried different connections, memory stick

  • Type a word in the address bar will take me more is the closest match. This feature has been removed?

    In all recent versions of firefox (that I remember), I was able to type in any word in the address bar and it would take me to what was usually the first result of google, now it takes me just a google search.For example, I could type in "Wikipedia"

  • Pavilion G 7: HP G7 administrator be able to password lock

    Just tried to log on my laptop of families and it shows enter administrator on disabled system password code 55171256, can you help me in this? Thank you Da