MarkLogic Server 11.0 Product Documentation
admin.databaseGetRangePolicyPartitionKey

admin.databaseGetRangePolicyPartitionKey(
   range-policy as element(db.assignmentPolicy)
) as cts.reference

Summary

This function returns the range policy partition key set for the database.

Parameters
range-policy The range assignment policy returned from the admin.databaseGetAssignmentPolicy function.

Required Privileges

This operation requires at least one of the following privileges:

http://marklogic.com/xdmp/privileges/admin/database

http://marklogic.com/xdmp/privileges/admin/database/{id}

Example

const admin = require('/MarkLogic/admin.xqy');
const config = admin.getConfiguration()
const dbid = admin.databaseGetId(config, "myDatabase")
const policy = admin.databaseGetAssignmentPolicy(config, dbid)
admin.databaseGetRangePolicyPartitionKey(policy)

    
Powered by MarkLogic Server | Terms of Use | Privacy Policy