Re: Various Questions - Mailing list pgsql-performance

From Shridhar Daithankar
Subject Re: Various Questions
Date
Msg-id 200312011856.04009.shridhar_daithankar@myrealbox.com
Whole thread Raw
In response to Various Questions  (Evil Azrael <evilazrael@evilazrael.de>)
List pgsql-performance
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´s about the speed?

It should not matter. Both commit and rollback should take same amount of
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´t tweak the
> cost setting for the GEQO?

I thought GEQO was triggered by numebr of join clauses. That is what GEQO cost
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,
you can probably create the index before querying and drop it later. However
even this will cost a seq. scan of table and can be heavy on performance..
 Take your pick

Shridhar


pgsql-performance by date:

Previous
From: Evil Azrael
Date:
Subject: Various Questions
Next
From: Erik Norvelle
Date:
Subject: My indexes aren't being used (according to EXPLAIN)