[PERFORM] sequence scan on PK

2005-05-08 Thread Jeroen van Iddekinge
Hi, I understand that when a table contains only a few rows it is better to do a sequence scan than an index scan. But is this also for a table with 99 records? A table contains id integer (primary key) namevarchar(70)

Re: [PERFORM] sequence scan on PK

2005-05-08 Thread Jeroen van Iddekinge
You could tweak with several settings to get it to do an index scan earlier, but these would probably break other queries. You don't need to tune for 100 rows, morelike 100k or 100M. Thanks for respone. The index scan was a little bit faster for id=1 and faster for id=99. Which settings shoud I ch

Re: [PERFORM] sequence scan on PK

2005-05-08 Thread Jeroen van Iddekinge
You should lower random_page_cost to make the planner choose an index scan vs sequential scan. Yes , it was a bit to high (18) so a lowered it. It speeded up some pages for about 5%. Reg. Jer ---(end of broadcast)--- TIP 1: subscribe and unsubscr

Re: [PERFORM] sequence scan on PK

2005-05-08 Thread Jeroen van Iddekinge
Matteo Beccati wrote: Hi, Yes , it was a bit to high (18) so a lowered it. It speeded up some pages for about 5%. 18? The default is 4 if I can remember correctly. I wonder if your db has ever seen an index scan ;) I was expermenting how much some setting influence has on the perfomance of som

[PERFORM] Performance problem with pg8.0

2005-11-06 Thread Jeroen van Iddekinge
Hello, I have some strange performance problems with quering a table.It has 5282864, rows and contains the following columns : id ,no,id_words,position,senpos and sentence all are integer non null. Index on : * no * no,id_words * id_words * senpos, sentence, "no") * d=prima