admin.databaseGeospatialPathIndex( pathexpr as String, coordinate-system as String, range-value-positions as Boolean, point-format as String, invalid-values as String ) as element(db.geospatialPathIndex)
This function constructs a geospatial path index specification. For usage details, see Geospatial Path Point Queries and Indexes in the Search Developer's Guide.
const admin = require('/MarkLogic/admin.xqy'); admin.databaseGeospatialPathIndex( "/aaa.a/aaa.b", "wgs84", fn.false(), "longLatPoint", "reject" ) => <geospatialPathIndex xmlns="http://marklogic.com/xdmp/database"> <pathExpression>/aaa.a/aaa.b</pathExpression> <coordinateSystem>wgs84</coordinateSystem> <pointFormat>longLatPoint</pointFormat> <rangeValuePositions>false</rangeValuePositions> <invalidValues>reject</invalidValues> </geospatialPathIndex>
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.