List:General Discussion« Previous MessageNext Message »
From:Chris Elsworth Date:October 20 2004 7:17am
Subject:Re: match a fulltext search with a "-" dash, can't match if - exist
View as plain text  
On Mon, Oct 18, 2004 at 11:19:55AM +0800, Louie Miranda wrote:
> 
> mysql> select * from fullsearch where match (title,body) against ('018-E');
> Empty set (0.00 sec)
> 
> 
> it returns an empty set, is it possible to also search with "-" dash? chars?

If I remember correctly, you need to pass the string as a phrase to fulltext:

select * from fullsearch where match (title,body) against ('"018-E"');

I'd prefer being able to escape the - with \, since using a phrase has
other disadvantages (like partial word matching goes out the window),
but you can't.

-- 
Chris
Thread
match a fulltext search with a "-" dash, can't match if - existLouie Miranda18 Oct
  • Re: match a fulltext search with a "-" dash, can't match if - existBertrand Gac18 Oct
  • Re: match a fulltext search with a "-" dash, can't match if - existChris Elsworth20 Oct
    • Re: match a fulltext search with a "-" dash, can't match if - existLinda Tan21 Oct