Results 1 to 7 of 7
  1. #1
    Join Date
    Jul 2010
    Posts
    4

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

    Hi,

    I am facing a problem after migration of Oracle from 8i to 11g. The following was workign fine in 8i.

    When i click the edit button on one of our application, it is throwign the follwoign error:
    PLS-00306: wrong number or types of arguments in call to 'ACTION'



    I am using a type table of varchar2tabtyp in a particular package, say 'package1'. The following is the piece of code:

    type varchar2tabtyp is table of varchar2(2000) index by binary_integer;
    null_varchar2tab varchar2tabtyp;
    procedure procA
    (actionA in varchar2
    ,methodA in varchar2 default 'post'
    ,attributeA in varchar2 default null);
    function procA
    (actionA in varchar2
    ,methodA in varchar2 default 'post'
    ,attributeA in varchar2 default null
    ) return varchar2;



    I have written the above in package1's spec. But i am calling this type for another package spec. So the spec for the second package (package2) is like below:

    PACKAGE PACKAGE2
    procedure proc2(
    var1 in varchar2 default null
    var2 package1.varchar2tabtyp default package1.null_varchar2tab
    var3 package1.varchar2tabtyp default package1.null_varchar2tab
    );

    and then I am calling in the package2 body the following:
    package1.procA('package2.proc2');


    Please help me out in this.

    Thanks a lot in advance.

    PS: the above codes are called on the click of a button. Once the button is clicked, it throws the error:
    ORA-06550: line 3, column 3:
    PLS-00306: wrong number or types of arguments in call to 'proc2'
    ORA-06550: line 3, column 3:
    PL/SQL: Statement ignored

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >and then I am calling in the package2 body the following:
    >package1.procA('package2.proc2');

    try removing the single quote marks.
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  3. #3
    Join Date
    Jul 2010
    Posts
    4

    am sorry, but it is not working

    I have the proc2 in the spec of package 'package2'. When i tried compiling after removing the quotes, it throws a compile time error:
    Error: PLS-00222: no function with name 'ACTION' exists in this scope

  4. #4
    Join Date
    Jul 2010
    Posts
    4
    Quote Originally Posted by anacedent View Post
    >and then I am calling in the package2 body the following:
    >package1.procA('package2.proc2');

    try removing the single quote marks.
    Can you please help me in this? I am not getting any clue to this.

  5. #5
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    >package1.procA('package2.proc2');

    Nothing you posted shows anything invokes "proc2" so produces the error below

    >PLS-00306: wrong number or types of arguments in call to 'proc2'
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  6. #6
    Join Date
    Feb 2005
    Posts
    57
    Show us the relevant bit of code from package1.procA that tries to call 'package2.proc2' that you pass as a parameter.

  7. #7
    Join Date
    Mar 2010
    Location
    Vienna, Austria
    Posts
    149
    AditiS,

    according to your definition of package1 the procedure procA expects (at least) one argument of the type varchar2.

    Package2.proc2 is a PROCEDURE (that doesn't return a value) and not a function.

    So what do you expect, when using a procedure as argument of another procedure ?
    "There is always an easy solution to every problem - neat, plausible, and wrong."
    -- H.L. Mencken

Posting Permissions

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