Skip site navigation (1) Skip section navigation (2)

Re: Plannner favoring nested loop

From: Abu Mushayeed <abumushayeed(at)yahoo(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Plannner favoring nested loop
Date: 2007-05-07 22:30:01
Message-ID: 952451.30909.qm@web57105.mail.re3.yahoo.com (view raw or flat)
Thread:
Lists: pgsql-admin
My default_statistics_target in the postgresql.conf file is set at 250. The tables are vacuumed everyday. Now, does that mean, for each column or only for the column on which index exist, increase the value of "statistics" value, so while analyzing it uses more rows in the sample.

  Thanks
  Abu
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
  Abu Mushayeed writes:
> I am trying to determine if I can make the planner see that nested loop is very expensive while it is trying to do an plan for a query and not pick that route. 

If it's doing that when it shouldn't, it's probably because it's
underestimated the number of rows in the outer relation. Look to your
stats settings.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend


       
---------------------------------
Ahhh...imagining that irresistible "new car" smell?
 Check outnew cars at Yahoo! Autos.

In response to

pgsql-admin by date

Next:From: Anoo PillaiDate: 2007-05-08 12:21:12
Subject: Time of previous REINDEX execution..
Previous:From: Tom LaneDate: 2007-05-07 21:37:33
Subject: Re: Plannner favoring nested loop

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group