Re: BETWEEN Help

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: BETWEEN Help
Дата
Msg-id 24586.1018828918@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: BETWEEN Help  (Bruce Momjian <pgman@candle.pha.pa.us>)
Ответы Re: BETWEEN Help  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-patches
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Tom Lane wrote:
>> Yup, that's one place that will need to be taught about it.

> That was actually a reason I was wondering if it was worth changing our
> current BETWEEN code.  The optimizer already is complicated and trying
> to do BETWEEN rather than the more simpler statements didn't seem like a
> win.

Actually, an explicit representation of BETWEEN will *help* the
optimizer; right now it has to try to recognize range restrictions
by matching up '>' and '<' clauses.  That's a mess already, and I
had no intention of trying to extend that logic to recognize the
clause structures that BETWEEN SYMMETRIC would put out if it weren't
a primitive node type.  But if it's a node then recognizing it is
a no-brainer.  See clausesel.c.

            regards, tom lane

В списке pgsql-patches по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: TOAST index naming consistency
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: BETWEEN Help