Re: How to disable auto-commit in postgresql-9.4 - Mailing list pgsql-novice

From Albe Laurenz
Subject Re: How to disable auto-commit in postgresql-9.4
Date
Msg-id A737B7A37273E048B164557ADEF4A58B365DC1DB@ntex2010a.host.magwien.gv.at
Whole thread Raw
In response to How to disable auto-commit in postgresql-9.4  (Nirban Sen <sennirban89@gmail.com>)
List pgsql-novice
Nirban Sen wrote:
> I am using postgresql-9.4 ,but not able to disable auto-commit.So I tried to disable it using SET
> AUTOCOMMIT { = | TO } { ON | OFF } but it no twork.
> I will be grateful if you let me know as soon as possible.

The last PostgreSQL server version that had such a feature was 7.3.

Ever since, you cannot disable autocommit in PostgreSQL.

However, psql has such a feature which you can enable by
   \set AUTOCOMMIT off
With that, psql will emulate "autocommit off" by automatically issuing
BEGIN before any statement if no transaction is already open.

Yours,
Laurenz Albe


pgsql-novice by date:

Previous
From: Nirban Sen
Date:
Subject: How to disable auto-commit in postgresql-9.4
Next
From: amul sul
Date:
Subject: Re: How to disable auto-commit in postgresql-9.4