Loading TOC...

MarkLogic Server 11.0 Product Documentation
alert.ruleUserIdQuery

alert.ruleUserIdQuery(
   user-ids as (Number|String)[]
) as cts.query

Summary

This function creates a query to find rules with any of the specified user IDs. Returns a query to be passed to alert.getMyRules or alert.getAllRules.

Parameters
user-ids A list of user IDs for the rules to be retrieved.

Example

  const alert = require("/MarkLogic/alert.xqy");

  alert.getAllRules(
        "http://acme.com/alert/message-board", 
        alert.ruleUserIdQuery(["7071164303237443533"]))

  =>Returns the rules with user ID ID7071164303237443533.
  

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.