pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: somloieater@gmail.com
To: pgsql-bugs@postgresql.org
Subject: BUG #7999: Regexp  with utf8
Date: Wed, 27 Mar 2013 10:32:57 +0000
Message-ID: <E1UKnf7-0005Sa-L4@wrigleys.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

The following bug has been logged on the website:

Bug reference:      7999
Logged by:          david
Email address:      somloieater@gmail.com
PostgreSQL version: 9.1.8
Operating system:   linux
Description:        


\y and \Y do not behave correctly next to
multibyte utf-8 characters - they seem to invert their sensesː

Propper behaivour with ascii e
'es'~$$\y[eɛ]s$$  => t 
Inverted behaviour with epsilon
'ɛs'~$$\y[eɛ]s$$  => f
'ɛs'~$$[eɛ]\ys$$  => t
'ɛs'~$$[eɛ]\Ys$$  => f

This seems to be a case of utf8 characters not being recognised as
word-forming:

'ɛ'~$$\w'$$ => f

I've checked with a few other characters which are >1byte in utf8. U+00F0
counds as \w, but nothing I've tried > FF matches. I wonder if it's
something to do with >256? 

In case anyone else hits this bug, replacing \y with
  (^|$|\s|[[:punct:]]) seems to work for me, although it's ugly.



-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (2+ messages)  latest in thread

Message-ID: <E1UKnf7-0005Sa-L4@wrigleys.postgresql.org>
Permalink:  ../E1UKnf7-0005Sa-L4@wrigleys.postgresql.org/
Also on:    postgresql.org/message-id/E1UKnf7-0005Sa-L4@wrigleys.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: somloieater@gmail.com
  Subject: Re: BUG #7999: Regexp  with utf8
  In-Reply-To: <E1UKnf7-0005Sa-L4@wrigleys.postgresql.org>
  References: <E1UKnf7-0005Sa-L4@wrigleys.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox