title: How to set the autocommit feature after each transaction with the information on what stage is the whole conversion
body: <p><strong>Hi everyone!</strong> This is my first request. In short introduction I would like to just point out that I'm still weak from SQL but I learn quickly. In the last days I wrote a very big <strong>SQL code</strong> in <strong>Postgresql</strong>, that is divided into several stages and is intended to support the work of my colleagues in the financial industry.</p>
  
  <hr>
  
  <p>Each of the queries I placed in the function separated by semicolons, and it works without a problem. Unfortunately the code optimization is still not my strong side because the entire function (all 40 scripts query) the one transaction for a very long time, a couple of hours.</p>
  
  <hr>
  
  <p>I would like to ask you for a hint how to add to the function (how and where) a script that automatically approves the particular stage of the conversion and will display the informations in the "Messages" that part of the code has been converted correctly and that part of the code shall be converted at the current time. I was looking for solutions have this in Postgres documentation and generally on the Internet but all I found is so chaotically written, that I can not cope. I will be very grateful for your support!</p>