Re: ERROR: syntax error in tsquery - for high-unicode whitespace - Mailing list pgsql-bugs

From Tom Lane
Subject Re: ERROR: syntax error in tsquery - for high-unicode whitespace
Date
Msg-id 20977.1363319779@sss.pgh.pa.us
Whole thread Raw
In response to ERROR: syntax error in tsquery - for high-unicode whitespace  (hubert depesz lubaczewski <depesz@depesz.com>)
Responses Re: ERROR: syntax error in tsquery - for high-unicode whitespace
List pgsql-bugs
hubert depesz lubaczewski <depesz@depesz.com> writes:
> $ select to_tsquery('english', E'a\xe2\x80\x86a');
> ERROR:  syntax error in tsquery: "a a"

> the 3-byte utf8 character is SIX-PER-EM SPACE (based on info from
> http://www.fileformat.info/info/unicode/char/2006/index.htm)

AFAICS, that behavior is correct, if you're using a locale that reports
  as being whitespace.  Compare

u8e=# select to_tsquery('english', E'a a');
ERROR:  syntax error in tsquery: "a a"

You need an ampersand or something in there.
Or use plainto_tsquery().

            regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #7943: plpgsql parsing bug
Next
From: hubert depesz lubaczewski
Date:
Subject: Re: ERROR: syntax error in tsquery - for high-unicode whitespace