I think what you are looking for is
Compound SQL (Embedded):
Combines one or more other SQL statements (sub-statements) into an
executable block.
BEGIN COMPOUND ATOMIC/NOT ATOMIC
sql-statement ;
END COMPOUND
or
label: begin atomic
declare
variable declaration
sql procedure statement;
end label
check the
SQL reference from the IBM site
regards,
mujeeb