Examples of Index Path Expressions
- Last Updated: April 15, 2026
- 1 minute read
- MarkLogic Server
- Version 11.0
- Documentation
The following table provides examples of XPath expressions that are valid and invalid for defining a path range index.
Note:
Avoid creating multiple path indexes that end with the same element/attribute, as ingestion performance degrades with the number of path indexes that end in common element/attributes.
Valid |
Invalid |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/a[/b |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Namespace prefixes are permitted in all valid path expressions. Note that you can also use fn:matches and fn:contains as part of the path expression, but you cannot use other functions in the path expression. Use cts:valid-index-path to test if a path expression is valid for an index path.