Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2009
    Posts
    3

    Red face Unanswered: java.sql.SQLException: ORA-06550: line 1, column 7: PLS-00306: wrong number or types

    Hi all,

    I want small info on ORACLE DB. I have created a function in ORACLE DB. Now I want to execute the function. But I am getting this error ,

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

    Did you ever come across such an error?

    Please help me in solving this error ASAP.

    Thank you very much in advance,

    Urs,
    Prakash

  2. #2
    Join Date
    Nov 2003
    Posts
    2,935
    Provided Answers: 12
    Quote Originally Posted by CBKLP
    Did you ever come across such an error?
    Yes, when I passed the wrong number or types of arguments in a call to a function.

  3. #3
    Join Date
    Mar 2009
    Posts
    3
    Hi Shammat,

    Thank GOD atelast one who has faced the same error. Can you please guide how to get rid of such an error?

    I need it very urgently..

    Thanks,
    CBKLP.

  4. #4
    Join Date
    Nov 2003
    Posts
    2,935
    Provided Answers: 12
    I supplied the correct number of arguments or types.

  5. #5
    Join Date
    Mar 2009
    Posts
    3
    Hi Shammat,

    Here I will explain you clearly. I have created one sample Function as,
    CREATE FUNCTION get_ID(Person_Name IN VARCHAR2)
    RETURN NUMBER
    IS Person_ID NUMBER;BEGIN
    SELECT ID
    INTO Person_ID
    FROM ORACLEDB
    WHERE NAME = Person_Name;RETURN(Person_ID);END;

    This is how it looks,

    FUNCTION get_ID(Person_Name IN VARCHAR2)
    RETURN NUMBER
    IS Person_ID NUMBER;BEGIN
    SELECT ID
    INTO Person_ID
    FROM ORACLEDB
    WHERE NAME = Person_Name;RETURN(Person_ID);END;

    Now I want to pass value to Person_Name and get the ID of that particular person.

    When I executed with some value, I am facing the above error.
    Can you please help me how we can call this function with a paramter and get the results back?

    Thank you very for your help.

    Prakash

  6. #6
    Join Date
    Nov 2003
    Posts
    2,935
    Provided Answers: 12
    OK, let me check the code....

    Ah, wait....
    I just realized I don't have your code where you call that function.

Posting Permissions

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