4

Is there a way to use the FullText query components to generate the list of words in the FullText dictionary that are the inflectional formsof a word?

This query would give me matches based on the query.

select *
from keywords
WHERE CONTAINS(keyword, 'FORMSOF(INFLECTIONAL, migrate)')

I am interested in words that it's using as matches. I want a list of words like

migrate
migrates
migration
migrations

Essentially the word's inflectional / conjugated forms.

5

You can find the words that will be used in the match with the sys.dm_fts_parser function in SQL Server.

The Syntax

sys.dm_fts_parser('query_string', lcid, stoplist_id, accent_sensitivity)

I won't go in details for the parameters values, but the "lcid" is important. In the example below I'm using 1033 which is for English - US. I've tried with 1036, French - Standard, and for sure I didn't get any results beside the word itself, since the word doesn't exist in the French dictionary.

Example

SELECT display_term
FROM SYS.DM_FTS_PARSER('FORMSOF(INFLECTIONAL, welcome)', 1033, 0, 0)

Result

welcome's
welcomed
welcomes
welcomes'
welcoming
welcome

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.