REGULAR EXPRESSION POSSIBLE PROBLEM

Started by devover 21 years ago2 messagesbugs
Jump to latest
#1dev
dev@strategma.bg

Hi PG team ,
my database is in UNICODE
I try this (with Bulgarian chars):

SELECT 'Тест проба' ~* 'тест' as result

returns FALSE

above query is same as:

SELECT 'Test exam' ~* 'test' as result

retuns TRUE

the only different is that strings are in English

Is there problem with cyrilic?
I tested postgresql server 8.0.0beta-4 in Win32 platform, but I have same
problem in linux/postgresql 7.4.x with UNICODE database.

Thanks in advanced.

regards Antony Raijekov

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: dev (#1)
Re: REGULAR EXPRESSION POSSIBLE PROBLEM

"dev" <dev@strategma.bg> writes:

my database is in UNICODE
I try this (with Bulgarian chars):

SELECT 'Тест проба' ~* 'тест' as result

returns FALSE

above query is same as:

SELECT 'Test exam' ~* 'test' as result

retuns TRUE

The regexp stuff is not currently capable of dealing with case
conversions in multi-byte character sets (such as Unicode).
Is there a Latin-N encoding you could use?

regards, tom lane