MarkLogic 9 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

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

  thsr.removeSynonym(thsr.lookup("/myThsrDocs/roget.xml", 
                               "car")[1],
                 {"term":"Fiat"})
  
Powered by MarkLogic Server | Terms of Use | Privacy Policy