PROCEDURĘ list_my_faults IS BEGIN
DECLARE Nested Błock 1
too_many_faults EXCEPTION;
BEGIN
... executable statements before new błock ... begin Nested Błock 2
SELECT SUM (faults) INTO nunufaults FROM profile ... ; IF num_faults > 100 THEN
-RAISE too_many_faults;
END IF;
EXCEPTION
WHEN NO_DATA_FOUND THEN ... ;
END;
... executable statements after Nested Błock 2 ... v EXCEPTION
*WHEN tOO_many_faultS THEN ... ;
END;
END list_my_faults;