Scara Maccai wrote:
Put the test-values into a temporary table, analyse it and then join
against it.
Ok, I didn't think of it.
Can't say about indexes without knowing more about your usage pattern.
What do you mean?
You might want an index on time, id, (id,time) or (time,id) - depends on
how many OR clauses there are typically and how many distinct values
there are for "time" and "id".
--
Richard Huxton
Archonet Ltd
---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?
http://archives.postgresql.org/