Re: Optimizer & boolean syntax
От | scott.marlowe |
---|---|
Тема | Re: Optimizer & boolean syntax |
Дата | |
Msg-id | Pine.LNX.4.33.0211211558530.23988-100000@css120.ihs.com обсуждение исходный текст |
Ответ на | Re: Optimizer & boolean syntax ("Christopher Kings-Lynne" <chriskl@familyhealth.com.au>) |
Список | pgsql-hackers |
On Thu, 21 Nov 2002, Christopher Kings-Lynne wrote: > > > I think his point is that they _should_ be equivalent. Surely there's > > > something in the optimiser that discards '=true' stuff, like 'a=a' > should be > > > discarded? > > > > I figure that's what he meant, but it isn't what was said. ;) > > > > "col" isn't of the general form "indexkey op constant" or "constant op > > indexkey" which I presume it's looking for given the comments in > > indxpath.c. I'm not sure what the best way to make it work would be given > > that presumably we'd want to make col IS TRUE/FALSE use an index at the > > same time (since that appears to not do so as well). > > Not that I see the point of indexing booleans, but hey :) While full indexes do seem futile, partial indexes can be quite useful. select articles from forum where approved is false if 99.9% of all articles are approved would be quite common.
В списке pgsql-hackers по дате отправления: