trgr:trigger-get-permissions( $trigger-name as xs:string ) as element(sec:permission)*
Returns the permissions for the named trigger.
Parameters | |
---|---|
trigger-name | The trigger name. |
The permissions on a trigger determine which roles may modify the trigger. This function must be run in the context of the database containing the trigger to be examined.
If the named trigger does not exist, the exception
TRGR-TRIGGERDNE
is raised.
xquery version "1.0-ml"; import module namespace trgr="http://marklogic.com/xdmp/triggers" at "/MarkLogic/triggers.xqy"; (: Run in the context of the database containing the trigger :) trgr:trigger-get-permissions("myTrigger") => <sec:permission xmlns:sec="http://marklogic.com/xdmp/security"> <sec:capability>update</sec:capability> <sec:role-id>6991745490888355329</sec:role-id> </sec:permission> <sec:permission xmlns:sec="http://marklogic.com/xdmp/security"> <sec:capability>read</sec:capability> <sec:role-id>6991745490888355329</sec:role-id> </sec:permission>