Postgresql, Autocommit, Procedure.
command. The error message should mention that we are either in a transaction block or in a recursive call. While here, I’ll mention a pgsql-hackers thread about another reason why we can get the same error, because an atomic context is forced by query snapshot management: “SPI Interface to Call