Case insensitive "contains" search

Поиск
Список
Период
Сортировка
От Wim Ceulemans
Тема Case insensitive "contains" search
Дата
Msg-id 000901be0bc3$9228d3b0$67faa8c0@aladdin.nice.be
обсуждение исходный текст
Ответы Re: [GENERAL] Case insensitive "contains" search  (Herouth Maoz <herouth@oumail.openu.ac.il>)
Re: [GENERAL] Case insensitive "contains" search  (Postgres DBA <postgres@nest.bistbn.com>)
Re: [GENERAL] Case insensitive "contains" search  (Oleg Broytmann <phd@sun.med.ru>)
Re: [GENERAL] Case insensitive "contains" search  (Ulf Mehlig <umehlig@uni-bremen.de>)
Список pgsql-general
Hi

A 'contains' search in postgreSQL is:

select * from tablex where name = '%test%';

When I want exactly the same but case insensitive, how do I do that? By
searching through the mail archive I came up with:

select * from tablex where name ~* 'test';

But this is not quite the same because it also finds for example 'tempest',
whereas the like search does not find it. So is there a postgreSQL operator
that does the same as the like %% search but case insensitive?


Regards

Wim Ceulemans
Nice Software Solutions
Eglegemweg 3, 2811 Hombeek - Belgium
Tel +32(0)15 41 29 53 - Fax +32(0)15 41 29 54




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

Предыдущее
От: Dustin Sallings
Дата:
Сообщение: dump problems:
Следующее
От: Herouth Maoz
Дата:
Сообщение: Re: [GENERAL] Case insensitive "contains" search