On Tue, 8 Apr 2008, Ow Mun Heng wrote:
I moved from multicolumn indexes to individual indexes because the
queries does not always utilise the same few indexes, some users would
use
eg: index F, A, B or D,A,E or any other combination.
Yes, that does make it more tricky, but it still may be best
On Mon, 2008-04-07 at 11:50 +0100, Matthew wrote:
> On Mon, 7 Apr 2008, Ow Mun Heng wrote:
> > just wondering if there's a special tweak i can do to force more usage
> > of indexes to do BITMAP ands?
>
> There's no need to post this again. You have already had a couple of
> useful answers.
Sorr
On Mon, 7 Apr 2008, Ow Mun Heng wrote:
just wondering if there's a special tweak i can do to force more usage
of indexes to do BITMAP ands?
There's no need to post this again. You have already had a couple of
useful answers.
Matthew
--
All of this sounds mildly turgid and messy and confusin
On Fri, 4 Apr 2008, Ow Mun Heng wrote:
select * from table
where A=X
and B = Y
and C = Z
and D = AA
and E = BB
With that kind of WHERE condition, Postgres will use a Bitmap Index Scan
to combine your indices. If, however, postgres notices while looking at
the statistics gathered during A
On Fri, 4 Apr 2008, Ow Mun Heng wrote:
select * from table
where A=X
and B = Y
and C = Z
and D = AA
and E = BB
This may not be the answer you're looking for, but if you create a
multi-coloumn index, it should be able to make your query run fast:
CREATE INDEX foo ON table (A, B, C, D, E);
It