[PERFORM] Query is not using index when it should

2004-12-12 Thread Tomas Skäre
I tried to subscribe to pgsql-performance, but there seems to be something wrong with the majordomo, so I'm sending to general too, where I'm already subscribed. My problem is this, using PostgreSQL 7.4.6: I have a table that looks like this: Table "public.cjm_object" Column |

Re: [PERFORM] [GENERAL] Query is not using index when it should

2004-12-12 Thread Tomas Skäre
"Steinar H. Gunderson" <[EMAIL PROTECTED]> writes: > On Sat, Dec 11, 2004 at 03:17:13PM +0100, Tomas Skäre wrote: > > select c.* from cjm_object c > > inner join > > (select max(timestamp) as timestamp,objectid,field from cjm_object > >group

Re: [PERFORM] [GENERAL] Query is not using index when it should

2004-12-11 Thread Tomas Skäre
Stephan Szabo <[EMAIL PROTECTED]> writes: > On Fri, 10 Dec 2004, Tomas [iso-8859-1] Skäre wrote: > > > I have a table that looks like this: > > > > Table "public.cjm_object" > > Column | Type| Modifiers > > ---+---+--- > > timestamp | bi