In "Statement-Based Replication Middleware", in "(PREPARE TRANSACTION and COMMIT PREPARED." missed closing parenthesis.
In "Synchronous Multimaster Replication" mentioned that "PostgreSQL does not offer this type of replication, though PostgreSQL two-phase commit (PREPARE TRANSACTION and COMMIT PREPARED) can be used to implement this in application code or middleware." But in "Notes" of "PREPARE TRANSACTION" menitioned that: "PREPARE TRANSACTION is not intended for use in applications or interactive sessions." I suggest to change to: "PREPARE TRANSACTION is not intended for typical use in applications or interactive sessions." Also in "Notes" of "PREPARE TRANSACTION" "It is not currently allowed to PREPARE a transaction" I suggest to change to: "It is not currently allowed to prepare a transaction". -- // Dmitry.