I'm fine tuning a Postgres database and I am about to set the maximun number of with prepared transactions with max_prepared_transactions.
The application uses a lot of prepared statements but not prepared transactions in the sense PREPARE name AS xyz.
My question is:
Yes. PREPARE TRANSACTION is used to initiate a two-phase transaction, which is generally used if you want to commit atomically to two databases at the same time.
Prepared statements relate to requesting the server to plan an SQL statement ahead of time, usually so that you can execute the statement multiple times without the overhead of planning it each time. See PREPARE.
The two are unrelated.
No, max_prepared_transactions
does not affect prepared statements.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With