Обсуждение: Upper and Lower case sensitivities

Поиск
Список
Период
Сортировка

Upper and Lower case sensitivities

От
"Campbell, Scott"
Дата:
Hey,

Is there a function within postgres that lets you search for both upper and
lower case at the same time?
I know of the upper() and lower() functions but if a word has both upper and
lower case in it it won't be returned by a query.
Or am I limited to forcing my data to have one case only?

Thanks
Scott

Re: Upper and Lower case sensitivities

От
Steve Heaven
Дата:
At 09:20 30/08/00 -0300, Campbell, Scott wrote:
>Hey,
>
>Is there a function within postgres that lets you search for both upper and
>lower case at the same time?
>I know of the upper() and lower() functions but if a word has both upper and
>lower case in it it won't be returned by a query.
>Or am I limited to forcing my data to have one case only?

select * from foo while column_name ~* 'matchstring';



Re: Upper and Lower case sensitivities

От
"Poul L. Christiansen"
Дата:
Try using ~*

Her are the General Operators:
http://www.postgresql.org/docs/user/x2125.htm

"Campbell, Scott" wrote:

> Hey,
>
> Is there a function within postgres that lets you search for both upper and
> lower case at the same time?
> I know of the upper() and lower() functions but if a word has both upper and
> lower case in it it won't be returned by a query.
> Or am I limited to forcing my data to have one case only?
>
> Thanks
> Scott