Hi,
I asked about this before and am still fighting for success;
any ideas I tried adding a index on jobtitle.
Explain analyze returns
QUERY PLAN
"Merge Join (cost=53053.05..53652.66 rows=4888
width=113) (actual time=9788.066..11042.584 rows=85694 loops=1)"
" Merge Cond: (""outer"".locationid
= ""inner"".locationid)"
" -> Sort (cost=604.65..605.45 rows=319 width=49)
(actual time=5.367..6.729 rows=402 loops=1)"
" Sort Key: l.locationid"
" -> Index Scan using ix_location on tbllocation
l (cost=0.00..591.38 rows=319 width=49) (actual time=0.193..3.548 rows=402
loops=1)"
" Index Cond: ('SAKS'::text = (clientnum)::text)"
" -> Sort (cost=52448.40..52710.82 rows=104970
width=75) (actual time=9782.634..10100.572 rows=85695 loops=1)"
" Sort Key: a.locationid"
" -> Merge Right Join
(cost=39859.63..41130.10 rows=104970 width=75) (actual time=6811.114..8284.253
rows=99139 loops=1)"
" Merge Cond: (((""outer"".clientnum)::text
= ""inner"".""?column10?"") AND
(""outer"".id = ""inner"".jobtitleid))"
" -> Index Scan using ix_tbljobtitle_id
on tbljobtitle jt (cost=0.00..226.47 rows=6343 width=37) (actual
time=0.089..33.082 rows=5662 loops=1)"
" Filter: (1 = presentationid)"
" -> Sort (cost=39859.63..40122.06
rows=104970 width=53) (actual time=6763.992..7160.587 rows=99139 loops=1)"
" Sort Key: (a.clientnum)::text, a.jobtitleid"
" -> Seq Scan on tblassociate a
(cost=0.00..31105.34 rows=104970 width=53) (actual time=0.478..1831.000
rows=99139 loops=1)"
" Filter: ((clientnum)::text =
'SAKS'::text)"
"Total runtime: 11319.403 ms"
Joel Fradkin
Wazagua, Inc.
2520 Trailmate Dr
Sarasota, Florida 34243
Tel. 941-753-7111 ext 305
[EMAIL PROTECTED]
www.wazagua.com
Powered by Wazagua
Providing you with the latest Web-based technology & advanced tools.
© 2004. WAZAGUA, Inc. All rights reserved. WAZAGUA, Inc
This email message is for the use of the intended recipient(s) and may
contain confidential and privileged information. Any unauthorized review,
use, disclosure or distribution is prohibited. If you are not the
intended recipient, please contact the sender by reply email and delete and
destroy all copies of the original message, including attachments.