pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kenneth Marshall <ktm@rice.edu>
To: Richard Broersma <richard.broersma@gmail.com>
Cc: Andy Colson <andy@squeakycode.net>
Cc: Justin Pitts <justinpitts@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Compared MS SQL 2000 to Postgresql 9.0 on Windows
Date: Tue, 7 Dec 2010 14:10:28 -0600
Message-ID: <20101207201028.GE4028@aart.is.rice.edu> (raw)
In-Reply-To: <AANLkTin4K86j2-GOUfmdXQ8UKv_j9V8ZRiRBEbbXj+jc@mail.gmail.com>
References: <378e24d1e3af88a49fbbb7c4d26f441a@mail.gmail.com>
	<4CFE7964.80206@squeakycode.net>
	<AANLkTi=HiO8ErFwzqBvgjXXHRUMKeUWqCpL-p9Y+oL_-@mail.gmail.com>
	<4CFE8E59.2010505@squeakycode.net>
	<AANLkTin4K86j2-GOUfmdXQ8UKv_j9V8ZRiRBEbbXj+jc@mail.gmail.com>

On Tue, Dec 07, 2010 at 11:56:51AM -0800, Richard Broersma wrote:
> On Tue, Dec 7, 2010 at 11:43 AM, Andy Colson <andy@squeakycode.net> wrote:
> 
> > In PG the first statement you fire off (like an "insert into" for example)
> > will start a transaction. ?If you dont commit before you disconnect that
> > transaction will be rolled back. ?Even worse, if your program does not
> > commit, but keeps the connection to the db open, the transaction will stay
> > open too.
> 
> Huh - is this new?  I always thought that every statement was wrapped
> in its own transaction unless you explicitly start your own.  So you
> shouldn't need to commit before closing a connection if you never
> opened a transaction to begin with.
> 
> 
> -- 
> Regards,
> Richard Broersma Jr.
> 

The default of autocommit unless explicitly starting a transaction with
BEGIN is the normal behavior that I have seen as well.

Cheers,
Ken



view thread (31+ messages)  latest in thread

Message-ID: <20101207201028.GE4028@aart.is.rice.edu>
Permalink:  ../20101207201028.GE4028@aart.is.rice.edu/
Also on:    postgresql.org/message-id/20101207201028.GE4028@aart.is.rice.edu

 · 

reply

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 using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: ktm@rice.edu, richard.broersma@gmail.com, andy@squeakycode.net, justinpitts@gmail.com
  Subject: Re: Compared MS SQL 2000 to Postgresql 9.0 on Windows
  In-Reply-To: <20101207201028.GE4028@aart.is.rice.edu>

* 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