Oracle Text (MOSC)

MOSC Banner

How to modify MySQL's full-text search engine to include the dash character

MySQL version: 8.0.22

We need to enable the MySQL full-text search engine to include the dash as a searchable character. By default it acts as string delimeter.

By default a dash (“-”) is not a searchable character so searching for RBIF-100 is analogous to “where title like (‘%RBIF%‘) or title like (‘%100%’)” — whereas we want it to function like “where title like (‘RBIF-100’)“.

This doc describes one 'fix' as:

Character Set Modifications

Modify a character set file: This requires no recompilation. The true_word_char() macro uses a “character type” table to distinguish letters and numbers from other characters. . You can edit the contents of the 

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center