Postgres setting autocommit off globally

前端 未结 2 948
孤独总比滥情好
孤独总比滥情好 2021-01-18 02:08

How do you set autocommit off in psql 8.4 at a global level? is there a configuration attribute that i can change that will introduce this behaviour for all dbs on a cluster

2条回答
  •  情书的邮戳
    2021-01-18 02:32

    Simply add the following to ~/.psqlrc:

    \set AUTOCOMMIT off 
    

    Note that this only works when using the psql shell! I assume this is what you are talking about?

提交回复
热议问题