xdmp.random

xdmp.random(
   [max as (Number|String)]
) as (Number|String)

Summary

Returns a random unsigned integer between 0 and a number up to 64 bits long.

Parameters
max The optional maximum value (inclusive).

Example

xdmp.random(100);
=> 47
Powered by MarkLogic Server | Terms of Use | Privacy Policy