Loading TOC...

MarkLogic Server 11.0 Product Documentation
thsr.removeSynonym

thsr.removeSynonym(
   entry as element(thsr.entry),
   synonym as element(thsr.synonym)|Object
) as null

Summary

Removes synonym $synonym from thesaurus entry $entry.

Parameters
entry A thesaurus entry.
synonym A synonym to be removed from a thesaurus entry, can either be an xml element or javascript object.

Example

  const thsr = require("/MarkLogic/thesaurus");
  declareUpdate();

  thsr.removeSynonym(thsr.lookup("/myThsrDocs/roget.xml", 
                               "car")[1],
                 {"term":"Fiat"})
  

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.