5 Replies Latest reply on Nov 10, 2015 9:10 PM by 2890297

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

    2890297

      HI

       

      I'm trying to run the attached program .I could not get the alignment properly hence attached it.

       

      But encountering the below error :

       

       

      **Starts**09-NOV-2015 10:51:03

      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 'CPDINVPO'

      ORA-06550: line 1, column 7:

      PL/SQL: Statement ignored

      .

       

       

      I have registered the program with parameter as  p_start_date(28-JAN-15) and p_end_date(29-JAN-15)  with value set -"Date".

       

      Please verify and suggest if something needs to be changed in the code.

        • 1. Re: PLS-00306: wrong number or types of arguments in call to 'CPDINVPO'
          Chris Hunt

          It means what it says.

          You have a piece of code - which you can see and we can't - called FDPSTP.

          You have a function or procedure - which you can see and we can't - called CPDINVPO, which expects a certain set of parameters (or arguments) when you call it.

          FDPSTP is calling CPDINVPO, but either sending the wrong number, or the wrong types of arguments (or maybe both).

           

          Please verify and suggest if something needs to be changed in the code.


          Change the bit I'm pointing at now. You should be able to see my finger the same way I can see your code.

          • 2. Re: PLS-00306: wrong number or types of arguments in call to 'CPDINVPO'
            PamNL

            If your submitting it using fnd_request.submit, it may have to do with the fact it still thinks the parameters are characters in a certain format representing a date. Usually it expects something like DD-MON-YYYY HH24:MI:SS ...

            You could change the parameters in chars and see what it passes in the log file.

            • 3. Re: PLS-00306: wrong number or types of arguments in call to 'CPDINVPO'
              Cuauhtemoc Amox

              If you register a pl/sql subprogram as a concurrent program, you need the following as the first two parameters, which are used to return the finalization status and message (no need to define them as program parameters, though):

               

              ERRBUF OUT VARCHAR2,

              RETCODE OUT VARCHAR2

               

              As per the developer's guide:

               

              Your stored procedure concurrent program is restricted to 100

              parameters in addition to the first two parameters, which are required

              and must be specified exactly as indicated in the example above. (You

              must take these two parameters into account when you create your

              stored procedure.) Use errbuf to return any error messages, and retcode

              to return completion status. The parameter retcode returns 0 for

              success, 1 for success with warnings, and 2 for error. After your

              concurrent program runs, the concurrent manager writes the contents

              of both errbuf and retcode to the log file associated with your concurrent

              request

              • 4. Re: PLS-00306: wrong number or types of arguments in call to 'CPDINVPO'
                PamNL

                Can you try this? You can catch exception at the end

                 

                CREATE OR REPLACE PROCEDURE CPDINVPO

                ( errbuf out varchar2

                , retcode out number

                , p_start_date IN varchar2

                ,p_end_date  IN varchar2

                )

                AS

                  l_start_date  DATE;

                  l_end_date  DATE;

                 

                ...

                BEGIN

                    l_start_date  := fnd_date.canonical_to_date (p_start_date);

                    l_end_date    := fnd_date.canonical_to_date (p_end_date);

                 

                  errbuf := null; retcode := 0;


                  ...

                  EXCEPTION

                   WHEN Others THEN   

                     errbuf := sqlerrm;

                     retcode := 2;

                END;

                • 5. Re: PLS-00306: wrong number or types of arguments in call to 'CPDINVPO'
                  2890297

                  Thx Pam.It is working after changing the parameter data types.