Query Manipulation Server 26.2
Query Manipulation Server Help

# Send Synonym Queries that Replace Query Text

You can use QMS to replace all the text in a query with the result of a synonym rule.

By default, QMS replaces terms that match the synonym rule `KEYWORDS` field with all terms that match the synonym rule `CONCEPT` field. Other terms in the query are not changed.

You can set the SynonymReplace action parameter in the query to replace all the query text with the `CONCEPT`.

For example, if you have set:

    #DREFIELD KEYWORDS="labrador"
    #DREFIELD CONCEPT="dog"

The following query:

    action=Query&Text=I walk my labrador in the park&ExpandQuery=True

expands to:

    action=Query&Text=I walk my dog in the park

However, the following query:

    action=Query&Text=I walk my labrador&ExpandQuery=True&SynonymReplace=True

expands to:

    action=Query&Text=dog

NOTE: If you set the `SYNONYMREPLACE` field in a synonym rule, the value of the field overrides the value of the action parameter when the query matches that rule.

For example, if your query has the SynonymReplace action parameter set to `True` and it matches a rule that has the `SYNONYMREPLACE` field set to `FALSE`, QMS ignores the action parameter and does not replace the query text.

Copyright 2026 Open Text
Version 26.2 | Last updated April 2026

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: Knowledge Discovery Query Manipulation Server 26.2

Topic Title: Send Synonym Queries that Replace Query Text