admin.databaseFieldPath

admin.databaseFieldPath(
   field-path as String,
   weight as Number
) as element(db.fieldPath)

Summary

This function is a constructor for field-path element. The field path element is used to construct a field.

Parameters
field-path A valid XPath expression.
weight The path weight used in relevance calculations.

Example

const admin = require('/MarkLogic/admin.xqy');
admin.databaseFieldPath("/a/b", xs.double(2.0))
=>
  returns element(db.fieldPath)

    
Powered by MarkLogic Server | Terms of Use | Privacy Policy