What I've read, it should be possible in Postgresql 14 to add commit in a procedure, but in my case it raises an error. For testing it, I wrote following:
CREATE OR REPLACE PROCEDURE public.committest()
LANGUAGE plpgsql
AS $procedure$
declare
test bigint;
BEGIN
select id into test from "AUTH".info;
commit;
END;
$procedure$
;
Then execute with
call public.committest();
The error message is:
SQL-Fehler [2D000]: ERROR: invalid transaction termination
Wobei: PL/pgSQL function committest() line 6 at COMMIT
But it's only on the (ubuntu) server. On my local development environment, it is working. So I think, I need to configure something? But I can't find out what I need to configure.