Search Postgresql Archives

Re: Nested loop in simple query taking long time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Henrik Zagerholm <henke@xxxxxx> writes:
> Usually I can see what is wrong with queries but I can't figure out  
> why this query is slow.

Seems the main problem is here:

>                      ->  Bitmap Index Scan on tbl_archive_idx1   
> (cost=0.00..1150.47 rows=8 width=0) (actual time=1505.456..1505.456  
> rows=86053 loops=16)
>                            Index Cond: (tbl_share.pk_share_id =  
> tbl_archive.fk_share_id)

Why is this scan finding so many more rows than the planner expects?
Perhaps increasing the stats targets on these columns would help it
make a better estimate.

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux