Definition:
The BEGIN statement marks the start of an executable block of PL/SQL. A block may contain one or more PL/SQL statements, and all blocks must have the two keywords BEGIN and END.
DECLARE
variable declarations
BEGIN
sql statements
end;
Example Usage
This example creates a trigger and demonstrates the BEGIN statement:
CREATE OR REPLACE TRIGGER statement_level
BEFORE UPDATE
ON orders
DECLARE
vMsg VARCHAR2(30) := 'Statement Level Trigger Fired';
BEGIN
dbms_output.put_line(vMsg);
END statement_level;
/
Related Links: