MySQL Forums
Forum List  »  Full-Text Search

Re: Truncate operator in quoted expression?
Posted by: Mike Ruskai
Date: July 09, 2005 05:55AM

Standardizing the data isn't an option. I only used street addresses as an example. There are other fields where there is no standardized format.

In any case, according the documentation, when searching for a quoted expression, it basically treats it as two separate fulltext searches, then scans the result set for the quotes expression. In other words, using this:

where match(field) against('"foobar jones"') essentially the same as using this:

where match(field) against('foobar') or match(field) against('jones')

...then doing this against the result set:

where field like '%foobar jones%'

But the following is also possible:

where match(field) against('foobar') or match(field) against('jone*')

Assuming the above to be creating a temp table, one could then do:

where field like '%foobar jone%'

If there were "foobar jones" and "foobar jonestown" strings, both would be found.

That begs a question. Why is there no syntax to perform the above in a single query? The nature of a quoted expression search is precisely what I need, except for the lack of consistency with regard to the truncate operator. It's very nearly a bug, when you look at it that way.

I think I may try submitting it as such, with appropriate qualifications. Or perhaps even try implementing it myself.

Options: ReplyQuote

Written By
Re: Truncate operator in quoted expression?
July 09, 2005 05:55AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.