From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | "Joel Fradkin" <jfradkin(at)wazagua(dot)com> |
Cc: | "'Dave Held'" <dave(dot)held(at)arrayservicesgrp(dot)com>, "'PERFORM'" <pgsql-performance(at)postgresql(dot)org> |
Subject: | Re: speed of querry? |
Date: | 2005-04-15 22:38:09 |
Message-ID: | 8324.1113604689@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
"Joel Fradkin" <jfradkin(at)wazagua(dot)com> writes:
> Turning off merg joins seems to of done it but what do I need to do so I am
> not telling the system explicitly not to use them, I must be missing some
> setting?
> " -> Hash Left Join (cost=185.57..226218.77 rows=177236 width=75) (actual
> time=21.147..2221.098 rows=177041 loops=1)"
> " Hash Cond: (("outer".jobtitleid = "inner".id) AND
> (("outer".clientnum)::text = ("inner".clientnum)::text))"
It's overestimating the cost of this join for some reason ... and I
think I see why. It's not accounting for the combined effect of the
two hash clauses, only for the "better" one. What are the statistics
for tbljobtitle.id and tbljobtitle.clientnum --- how many distinct
values of each, and are the distributions skewed to a few popular values?
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Ron Mayer | 2005-04-16 00:10:45 | Re: Spend 7K *WHERE*? WAS Intel SRCS16 SATA raid? and How |
Previous Message | Rod Taylor | 2005-04-15 21:33:03 | Re: Spend 7K *WHERE*? WAS Intel SRCS16 SATA raid? and How |