On Thu, 2007-10-04 at 08:30 -0400, Alvaro Herrera wrote:
Henrik wrote:
Ahh I had exactly 8 joins.
Following your suggestion I raised the join_collapse_limit from 8 to 10 and
the planners decision sure changed but now I have some crazy nested loops.
Maybe I have some statistics wrong?
3 okt 2007 kl. 16:15 skrev Tom Lane:
Henrik [EMAIL PROTECTED] writes:
Here is the query if needed.
explain analyze SELECT file_name FROM tbl_file_structure JOIN
tbl_file ON pk_file_id = fk_file_id JOIN tbl_structure ON
pk_structure_id = fk_structure_id JOIN tbl_archive ON pk_archive_id
Henrik wrote:
Ahh I had exactly 8 joins.
Following your suggestion I raised the join_collapse_limit from 8 to 10 and
the planners decision sure changed but now I have some crazy nested loops.
Maybe I have some statistics wrong?
Yeah. The problematic misestimation is exactly the innermost
4 okt 2007 kl. 14:30 skrev Alvaro Herrera:
Henrik wrote:
Ahh I had exactly 8 joins.
Following your suggestion I raised the join_collapse_limit from 8
to 10 and
the planners decision sure changed but now I have some crazy
nested loops.
Maybe I have some statistics wrong?
Yeah. The
Henrik wrote:
Correct. I changed the statistics to 500 in tbl_file.file_name and now the
statistics is better. But now my big seq scan on tbl_file_Structure back
and I don't know why.
Hmm, I think the problem here is that it needs to fetch ~20 tuples
from tbl_file_structure one way or
Hello list,
I have a little query that takes too long and what I can see in the
explain output is a seq scan on my biggest table
( tbl_file_structure) which I can't explain why.
Here is the output. I hope this is formatted correctly. If not, let
me know and I'll paste it somewhere.
On Wed, Oct 03, 2007 at 10:03:53AM +0200, Henrik wrote:
I have a little query that takes too long and what I can see in the
explain output is a seq scan on my biggest table ( tbl_file_structure)
which I can't explain why.
Here's where almost all of the time is taken:
Hash Join
Henrik [EMAIL PROTECTED] writes:
Here is the query if needed.
explain analyze SELECT file_name FROM tbl_file_structure JOIN
tbl_file ON pk_file_id = fk_file_id JOIN tbl_structure ON
pk_structure_id = fk_structure_id JOIN tbl_archive ON pk_archive_id
=fk_archive_id JOIN tbl_share ON