I have this: SELECT ... FROM trade, entry WHERE AGE( CURRENT_TIMESTAMP, posted ) <= '5 minutes'::TIMESPAN AND trade.entryId = entry.entryId That is, fetch all trades executed in the last 5 minutes. This query seems to run pretty slowly when trade is filled. Putting an index on trade ( posted ) doesn't seem to help any (the same query plan is generated). Any suggestions? -itai
- Re: [SQL] Indices and time spans Itai Zukerman
- Re: [SQL] Indices and time spans Tom Lane
- Re: [SQL] Indices and time spans Itai Zukerman