select query optimization - Mailing list pgsql-sql

From sergey
Subject select query optimization
Date
Msg-id 44D3983F.60503@gmail.com
Whole thread Raw
List pgsql-sql
Hi all!
i run this query

select f1,f2
from t1,t2
where
t1.url_id=t2.entry_id and
(t1.entry_stamp::date>=(now()::date-interval '14 days')) and
....

the problem is that t1 is a very big table so the query is too slow.
what if i move the second condition to where-clause. Can this reduce the 
select time?

select f1,f2
from (select * from t1 where t1.entry_stamp::date>=(now()::date-interval 
'14 days' ) as t1,t2
where
t1.url_id=t2.entry_id and
....

Does this makes sense?
(tried to make explain analyze, but it takes too much time)

Thank you.


pgsql-sql by date:

Previous
From: "Jonathan Sinclair"
Date:
Subject:
Next
From: "Melvin Davidson"
Date:
Subject: to_dec()