pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Hasnul Fadhly bin Hasan <hasnulfadhly.h@mimos.my>
To: Michael Fuhr <mike@fuhr.org>
Cc: pgsql-performance@postgresql.org
Subject: Re: Autocommit
Date: Mon, 14 Feb 2005 16:58:31 +0800
Message-ID: <42106837.3020103@mimos.my> (raw)
In-Reply-To: <20050214084703.GA4038@winnie.fuhr.org>
References: <42105AD0.2010803@mimos.my>
	<20050214084703.GA4038@winnie.fuhr.org>

Hi Micheal,

Thanks for the reply.  I am using postgres 7.4.5 client.  There's one 
that is using 7.4.1 client.  I'm not sure if there would be any difference.
When i use psql and check the status of autocommit, it is set to 
enable.  I'm not sure if libpq and psql uses the same defaults.

Thanks,

Hasnul



Michael Fuhr wrote:

>On Mon, Feb 14, 2005 at 04:01:20PM +0800, Hasnul Fadhly bin Hasan wrote:
>  
>
>>I am just wondering, by default, autocommit is enabled for every client 
>>connection.  The documentations states that we have to use BEGIN
>>and  END or COMMIT so to increase performance by not using autocommit. 
>>My question is, when we use the BEGIN and END statements, is autocommit 
>>unset/disabled automatically or we have to disable/unset it manually?
>>    
>>
>
>What version of PostgreSQL is your server running and what client
>software are you using?  PostgreSQL 7.3 had a server-side autocommit
>setting, but it caused problems with some clients so 7.4 got rid
>of it and left autocommit up to the client.  How to enable or disable
>client-side autocommit depends on the client software, but if you're
>able to execute a BEGIN (or START TRANSACTION) statement then you
>should be inside a transaction until you execute COMMIT (or END)
>or ROLLBACK.  That is, unless your client intercepts these statements
>and does whatever it wants....
>
>  
>

view thread (4+ messages)  latest in thread

Message-ID: <42106837.3020103@mimos.my>
Permalink:  ../42106837.3020103@mimos.my/
Also on:    postgresql.org/message-id/42106837.3020103@mimos.my

 · 

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: hasnulfadhly.h@mimos.my, mike@fuhr.org
  Subject: Re: Autocommit
  In-Reply-To: <42106837.3020103@mimos.my>

* 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