10 Replies Latest reply on Dec 2, 2009 2:41 PM by user222828

    Problem with Stored Procedure exection in Oracle DB

    738444
      Hi,

      I am facing some problem while creating and executing a store procedure.
      Please help me solving my problem.

      Here are the details :

      My Store Procedure :

      PROCEDURE EMP2
      (PROCESSED IN VARCHAR2 ) AS
      BEGIN
      SELECT * FROM EMPLOYEE WHERE PROCESSED ='NO'
      UPDATE EMPLOYEE SET PROCESSED='YES' WHERE PROCESSED='NO'
      COMMIT;END EMP;

      Now I want to execute this SP with the statement,

      EXECUTE EMP2('NO');

      But When I execute this statement, it prompts with this error :

      Error: java.sql.SQLException: ORA-00900: invalid SQL statement
      , SQL State: 42000, Error Code:

      Please help me to solve this issue with high priority.

      Regards,
      Vara.