This content has been marked as final. Show 1 reply
You have to create the first procedure (addition), then run the pl/sql block:
The procedure is stored in the database, the pl/sql block is anonymous, it's not stored in the db.
SQL> Create or replace procedure addition 2 ( 3 P_A IN NUMBER 4 ,P_B IN NUMBER 5 ,P_C OUT NUMBER 6 )AS 7 BEGIN 8 P_C := P_A +P_B; 9 END ADDITION; 10 / Procedure created. SQL> declare 2 x number; 3 begin 4 addition (5,5,x); 5 dbms_output.put_line('the result is' || x); 6 end; 7 / the result is10 PL/SQL procedure successfully completed.