Postgres: reentrant statement use with bound parameters results in "Binding too many parameters" exception
Whenever a particular statement is already in use for a particular connection, we make a new statement with the same SQL, so it can be run concurrently.
However, we use
SqlStatement::sql() for that, which isn't necessarily the same as the original SQL.
Notably the Postgres backend replaces questionmarks with
$1 etc. This causes the parameter count to be off for the copy of the statement.