On Mon, Jun 26, 2017 at 9:35 PM, David G. Johnston <david.g.johns...@gmail.com> wrote: > We already have SET TRANSACTION READ ONLY.
But in my use-case I am OK with the query doing write operations, since sometimes you need to test something in prod (that cannot be tested easily locally) but you want to ROLLBACK the query as quickly as possible to avoid locking things longer than necessary. Currently I'm just manually appending "; rollback;" to the query to make sure its rollbacked. The best thing I can do today is to map some button on the keyboard to automatically type "; rollback; [enter]" instead of hitting [enter] to fire-off the query, but it would be nice if it was built-in psql so you could never commit something by mistake unless you explicitly exit the AUTOROLLBACK mode. -- Sent via pgsql-hackers mailing list (firstname.lastname@example.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers