Re: uncommited question

From: "Nigel J(dot) Andrews" <nandrews(at)investsystems(dot)co(dot)uk>
To: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
Cc: Rob Brown-Bayliss <rob(at)zoism(dot)org>, PostgreSQL General List <pgsql-general(at)postgresql(dot)org>
Subject: Re: uncommited question
Date: 2002-08-09 22:13:47
Message-ID: Pine.LNX.4.21.0208092309260.3235-100000@ponder.fairway2k.co.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Fri, 9 Aug 2002, Nigel J. Andrews wrote:

> On Fri, 9 Aug 2002, scott.marlowe wrote:
> >
> > Postgresql is in autocommit mode until you initiate a transaction with a
> > begin statement.
> >
> > I.e. when you enter the psql monitor, and type in:
> >
> > update table set field1='something' where id=45;
> >
> > Postgresql internally wraps the update in the equivalent of a begin;end;
> > pair.
> >
> > There was some talk of making psql run in a kind of auto-transact mode,
> > where it would throw a begin; when you started it up, and another when you
> > did a commit or rollback. I haven't seen any work done on it though. I
> > kinda prefer the way postgresql does it, but can understand the
> > advantages to the way Oracle et. al. do it.
>
>
> This caught me out when I started with PostgreSQL as well. It also took me a
> while to work out from the documentation that autocommit was not some sort of
> configuration parameter and was simply a BEGIN statement. If someone can bear
> the boredom I would request that the documentation is changed to make this
> clear. I might have a quick scan through the directory tree myself this weekend
> to see what format the docs are in.

Oops, I think I need another egg, I seem to have an as yet unegged spot on my
face.

Now I know when I started out I was confused and I was looking for an
autocommit configuration/settable type item but scanning the directory tree
I'll be blowed if I can find an occurrance of autocommit that doesn't mention
that this requires a BEGIN statement. Obviously I'm ignoring the ecpg, odbc and
jdbc interfaces that do seem to have an autocommit flag.

--
Nigel J. Andrews
Director

---
Logictree Systems Limited
Computer Consultants

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Nigel J. Andrews 2002-08-09 22:20:12 Re: oid's and primary keys on insert
Previous Message Andrew Sullivan 2002-08-09 22:07:31 Re: oid's and primary keys on insert