Andres>I think the biggestoverhead here is that the executor startup includes Andres>too many indirect (linked lists) datastructured, that allocated each Andres>round
The case is very common: batch inserts are popular in Java, and ORMs use batch API automatically. However, there's high per-backend-message overhead, and that overhead is very noticeable. What is the approach to handle this? Folding multiple DML statements into one with a help of CTE does not work either (see https://github.com/pgjdbc/pgjdbc/issues/1165 ): CTE doc>Trying to update the same row twice in a single statement is not supported. Only one of the modifications takes place, but it is not easy (and sometimes not possible) to reliably predict which one Vladimir