Re: "select ... where field like lower('%text%')" fails

Поиск
Список
Период
Сортировка
От Thomas Lockhart
Тема Re: "select ... where field like lower('%text%')" fails
Дата
Msg-id 3AA5007F.42835AED@alumni.caltech.edu
обсуждение исходный текст
Ответ на "select ... where field like lower('%text%')" fails  (pgsql-bugs@postgresql.org)
Список pgsql-bugs
There is no bug. You want case-insensitive pattern matching, which is
not what your call to "tolower()" accomplishes.

The query

  SELECT company from user_tbl where company like lower('%SEaN%');

will find all strings which contain "sean" (note case!). It will not
match strings containing "Sean". Look in the PostgreSQL docs for hints
on how to do case-insensitive searches.

                      - Thomas

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

Предыдущее
От: lonnie
Дата:
Сообщение: interface differences in the 7.0.3 version
Следующее
От: Ivan Baldo
Дата:
Сообщение: 7.0.3 - Backend crash on simple SELECT query