BEGIN TRANSACTION ISOLATION LEVEL SERIALIZABLE;
DO
$$
DECLARE
arg_1 int;
arg_2 int;
res int;
BEGIN
BEGIN
arg_1 := 10;
arg_2 := 0;
res := arg_1 / arg_2;
COMMIT;
EXCEPTION WHEN OTHERS THEN
ROLLBACK;
res := 0;
END;
END;
$$;
SQL Error [2D000]: ERROR: invalid transaction termination
Where: PL/pgSQL function inline_code_block line 12 at ROLLBACK