Re: Best Fit SQL query statement

Поиск
Список
Период
Сортировка
От hubert depesz lubaczewski
Тема Re: Best Fit SQL query statement
Дата
Msg-id 20070811090644.GA5255@depesz.com
обсуждение исходный текст
Ответ на Re: Best Fit SQL query statement  ("Rodrigo De León" <rdeleonp@gmail.com>)
Список pgsql-sql
On Fri, Aug 10, 2007 at 08:13:46PM -0500, Rodrigo De León wrote:
> On 8/10/07, hubert depesz lubaczewski <depesz@depesz.com> wrote:
> > unfortunatelly this query will be hard to optimize.
> 
> Uh, how about
> 
> SELECT MAX(t1)
>   FROM t1
>  WHERE '9849' LIKE t1 || '%';

it will not help much as the main burden is the where clause, which is
not indexable.

depesz

-- 
quicksil1er: "postgres is excellent, but like any DB it requires a
highly paid DBA.  here's my CV!" :)
http://www.depesz.com/ - blog dla ciebie (i moje CV)


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

Предыдущее
От: "Pavel Stehule"
Дата:
Сообщение: Re: Trigger Procedure Error: NEW used in query that is not in a rule
Следующее
От: Andreas Joseph Krogh
Дата:
Сообщение: Re: Index usage in order by with multiple columns in order-by-clause