X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id A7C5DD1D388 for ; Mon, 1 Dec 2003 13:27:06 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 95997-07 for ; Mon, 1 Dec 2003 09:26:38 -0400 (AST) Received: from smtp-send.myrealbox.com (smtp-send.myrealbox.com [192.108.102.143]) by svr1.postgresql.org (Postfix) with ESMTP id 43D90D1B46D for ; Mon, 1 Dec 2003 09:26:34 -0400 (AST) Received: from daithan.intranet.pspl.co.in shridhar_daithankar@smtp-send.myrealbox.com [202.54.11.72] by smtp-send.myrealbox.com with NetMail SMTP Agent $Revision: 3.44 $ on Novell NetWare via secured & encrypted transport (TLS); Mon, 01 Dec 2003 06:26:37 -0700 From: Shridhar Daithankar To: pgsql-performance@postgresql.org Subject: Re: Various Questions Date: Mon, 1 Dec 2003 18:56:03 +0530 User-Agent: KMail/1.5.4 References: <924548300.20031201140750@evilazrael.de> In-Reply-To: <924548300.20031201140750@evilazrael.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200312011856.04009.shridhar_daithankar@myrealbox.com> X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200312/3 X-Sequence-Number: 4863 On Monday 01 December 2003 18:37, Evil Azrael wrote: > 1) I have a transaction during which no data was modified, does it > make a difference whether i send COMMIT or ROLLBACK? The effect is the > same, but what=B4s about the speed? It should not matter. Both commit and rollback should take same amount of= =20 time.. > 2) Is there any general rule when the GEQO will start using an index? > Does he consider the number of tuples in the table or the number of > data pages? Or is it even more complex even if you don=B4t tweak the > cost setting for the GEQO? I thought GEQO was triggered by numebr of join clauses. That is what GEQO c= ost=20 indicates. It is not triggered by number of tuples in any table etc. But correct me if I am wrong. > 3) Makes it sense to add a index to a table used for logging? I mean > the table can grow rather large due to many INSERTs, but is also > seldom queried. Does the index slowdown noticable INSERTs? Yes. It does make a lot of difference. If the table is very seldom queried,= =20 you can probably create the index before querying and drop it later. Howeve= r=20 even this will cost a seq. scan of table and can be heavy on performance.. Take your pick Shridhar