
sec.removePath( path as String, path-namespaces as element(sec.pathNamespace)[] ) as null
This function removes protection from the specified protected path and removes the path from the Security database.
| Parameters | |
|---|---|
| path | The name of the path to remove. | 
| path-namespaces | The namespace(s) for the path to be removed. | 
http://marklogic.com/xdmp/privileges/remove-path
  This function must be executed against the Security database.
     // execute this against the Security database
    declareUpdate();
    const sec = require('/MarkLogic/security');
    sec.removePath("/root/bar[@baz=1]", []);
    sec.removePath("test", []);
    sec.removePath("/root/reg[fn:matches(@expr, 'is')]", []);
      
  
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.