alert:rule-set-user-id( $rule as element(alert:rule), $user-id as xs:unsignedLong ) as element(alert:rule)*
This function returns the rule with the user ID
updated. If the caller does not have the
alert-config
privilege, an exception will be
thrown if the caller attempts to save a rule for a user other
than himself.
Parameters | |
---|---|
$rule | The representation of a rule. |
user-id | The user ID value to set for the given rule. |
xquery version "1.0-ml"; import module namespace alert = "http://marklogic.com/xdmp/alert" at "/MarkLogic/alert.xqy"; alert:rule-set-user-id($rule, 123456789) => Returns the XML representation of the rule with the new user ID updated to 123456789