Re: [PERFORM] query becomes fas on 'SET enable_hashjoin TO off;'

2009-02-10 Thread Rajesh Kumar Mallah
On Tue, Feb 10, 2009 at 9:09 PM, Tom Lane wrote: > Rajesh Kumar Mallah writes: >> On Tue, Feb 10, 2009 at 6:36 PM, Robert Haas wrote: >>> I'm guessing that the problem is that the selectivity estimate for >>> co_name_vec @@ to_tsquery('plastic&tubes') is not very good, but I'm >>> not real famil

Re: [PERFORM] query becomes fas on 'SET enable_hashjoin TO off;'

2009-02-10 Thread Tom Lane
Rajesh Kumar Mallah writes: > On Tue, Feb 10, 2009 at 6:36 PM, Robert Haas wrote: >> I'm guessing that the problem is that the selectivity estimate for >> co_name_vec @@ to_tsquery('plastic&tubes') is not very good, but I'm >> not real familiar with full text search, so I'm not sure whether >> th

Re: [PERFORM] query becomes fas on 'SET enable_hashjoin TO off;'

2009-02-10 Thread Rajesh Kumar Mallah
Dear Robert, thanks for ur interest. Our server was too loaded what i posted my last observation, now the other explain analyze can also be run and i am posting both the result , as you can see latter is 55ms versus 3000 ms . explain analyze select lead_id from general.trade_leads join general.pr

Re: [PERFORM] query becomes fas on 'SET enable_hashjoin TO off;'

2009-02-10 Thread Robert Haas
On Tue, Feb 10, 2009 at 5:31 AM, Rajesh Kumar Mallah wrote: > I have a query in which two huge tables (A,B) are joined using an indexed > column and a search is made on tsvector on some column on B. Very limited > rows of B are expected to match the query on tsvector column. > > With default plan

[PERFORM] query becomes fas on 'SET enable_hashjoin TO off;'

2009-02-10 Thread Rajesh Kumar Mallah
Hi , I have a query in which two huge tables (A,B) are joined using an indexed column and a search is made on tsvector on some column on B. Very limited rows of B are expected to match the query on tsvector column. With default planner settings the query takes too long ( > 100 secs) , but with h