From: Federico Passaro <fede@link.it>
To: ajoppich@usa.net, PostgreSQL sql <pgsql-sql@postgreSQL.org>
Subject: Re: [SQL] Turn autocommit off ?
Date: Thu, 17 Sep 1998 16:46:11 +0200
Message-ID: <360120B3.9EAE4313@link.it> (raw)
References: <360118DF.37BC@usa.net>
Andreas Joppich wrote:
> Hi there !
>
> It has now happened several times that I wanted to rollback some
> changes (like update, delete,...) I made to some tables. And since I
> always forget to start a transaction, a simple ROLLBACK doesn't work
> because of that quiet annoying autocommit in psql.
>
> I'd like to have automatically started a transaction which explicitly
> must be termintated with commit or rollback.
>
> Is there a way to turn autocommit off ? If not, perhaps it could
> be a feature for the todo list ?
>
> I'm currently using the cvs from last sunday on linux 2.1.119.
>
> Thanks for any hints.
>
> Andreas
You can edit your ~/.psqlrc (or /etc/psqlrc) an put a
begin;
line into it. The drawback is that if you do not issue a "commit"
command you loose all your changes.
Cheers
federico
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: fede@link.it
Subject: Re: [SQL] Turn autocommit off ?
In-Reply-To: <360120B3.9EAE4313@link.it>
References: <360118DF.37BC@usa.net> <360120B3.9EAE4313@link.it>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox