On Monday, Mar 3, 2003, at 14:09 US/Pacific, Stephan Szabo wrote:
> If you're hitting all the rows in the table, there's only disadvantage
> to using an indexscan (right now, given the way data is stored). If
> you
> were returning some fraction of the rows postgresql should hopefully
> switch to a different plan (depending on the estimated costs).
I should only ever get one match per record. This is the structure of
the relevant tables:
Customer --> Customer_Month_Summary ^ |
EmailAddress
There is one Customer_Month_Summary record per-customer-per-month, so I
should only get one record out of the database. Additionally, since
there are about 2000 customer records, but multiple months in the
summary table, I'll never use the entire results of the summary table
in one query.