Re: [PERFORM] Why isn't this index being used?

2004-10-19 Thread Andrew Sullivan
On Tue, Oct 19, 2004 at 11:33:50AM -0400, Knutsen, Mark wrote: > (Why don't replies automatically go to the list?) Because sometimes you don't want them to. There's been dozens of discussions about this. BTW, mutt has a nice feature which allows you to reply to lists -- I imagine other MUAs have

Re: [PERFORM] Why isn't this index being used?

2004-10-19 Thread Knutsen, Mark
nutsen, Mark > Cc: [EMAIL PROTECTED] > Subject: Re: [PERFORM] Why isn't this index being used? > > Hi, I ran into a similar problem using bigints... > > See: > http://www.postgresql.org/docs/7.3/static/datatype.html#DATATYPE-INT > > small & big int have to be cast

Re: [PERFORM] Why isn't this index being used?

2004-10-19 Thread Doug Y
Hi, I ran into a similar problem using bigints... See: http://www.postgresql.org/docs/7.3/static/datatype.html#DATATYPE-INT small & big int have to be cast when used in querries... try: explain select * from db where type=90::smallint and subtype=70::smallint and date='7/1/2004'; or explain select

[PERFORM] Why isn't this index being used?

2004-10-19 Thread Knutsen, Mark
The following is from a database of several hundred million rows of real data that has been VACUUM ANALYZEd.   Why isn't the index being used for a query that seems tailor-made for it? The results (6,300 rows) take about ten minutes to retrieve with a sequential scan.   A copy of this d