why it does not work ? i run this in oracle . i want to create aprocedure like that:
CREATE OR REPLACE PROCEDURE ME( X in NUMBER )IS
declare
num1 number;
BEGIN
num1:=1;
insert into a (year) values(7);
END;
this is the error:
PLS-00103: Encountered the symbol "DECLARE" when expecting one of the following: begin function pragma procedure subtype type current cursor delete exists prior external language The symbol "begin" was substituted for "DECLARE" to continue. 7/5 PLS-00103: Encountered the symbol "end-of-file" when expecting one of the following: ( begin case declare end exception exit for goto if loop mod null pragma raise return select update while with << continue close current delete fetch lock insert open rollback savepoint set sql execute commit forall merge pipe purge