Skip to content
Advertisement

Fulltext search on partial word (like “prefix%”)

To search for a full word in a mysql fts search I can do:

select * from pdxa where match(_search ) against ('everywhere')

is there a way to just search for the start of a word, such as:

select * from pdxa where _search like 'every%'

Advertisement

Answer

In boolean mode, you can use * as a wildcard:

select * from pdxa where match(_search ) against ('every*' in boolean mode)
User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement