
sec:query-roleset( $role-names as xs:string+ ) as element(sec:query-roleset)
This function creates a query roleset that can be passed into a function used to add or remove rolesets.
| Parameters | |
|---|---|
| role-names | Names of the roles to be included in the roleset. | 
This function must be executed against the Security database.
 (: execute this against the Security database :)
 
xquery version "1.0-ml"; 
import module namespace sec = "http://marklogic.com/xdmp/security" 
      at "/MarkLogic/security.xqy";
sec:query-roleset("els-role-2")
=>
<query-roleset xmlns="http://marklogic.com/xdmp/security">
  <role-id>12006351629398052509
  </role-id>
</query-roleset>
    
  
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.