Try altering the stats target for the table, and run vacuum analyze. Then try your query again.
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Thomas Mueller Sent: Sunday, February 15, 2004 9:26 AM To: dbmail-dev@dbmail.org Subject: Re: [Dbmail-dev] some speed tests Hi John, > Try: explain SELECT mailbox_idnr FROM mailboxes WHERE > owner_idnr=2::bigint; No difference: dbmail=> explain SELECT mailbox_idnr FROM mailboxes WHERE owner_idnr=2::bigint; QUERY PLAN --------------------------------------------------------- Seq Scan on mailboxes (cost=0.00..1.06 rows=3 width=8) Filter: (owner_idnr = 2::bigint) > dbmail=> explain SELECT mailbox_idnr FROM mailboxes WHERE owner_idnr=2; > QUERY PLAN > --------------------------------------------------------- > Seq Scan on mailboxes (cost=0.00..1.06 rows=3 width=8) > Filter: (owner_idnr = 2) > (2 rows) > > The table has an index on owner_idnr. -- MfG Thomas Mueller - http://www.tmueller.com for pgp key (95702B3B) _______________________________________________ Dbmail-dev mailing list Dbmail-dev@dbmail.org http://twister.fastxs.net/mailman/listinfo/dbmail-dev