Search code examples
xquerymarklogicmarklogic-8

MarkLogic 8 - XQuery - cts query to find document property by value


Is there a way to find documents with a specific property value in the document properties?

Follow-up question, are the document properties indexed?

(Properties meaning the xdmp:document-add-properties() kind)


Solution

  • You can wrap arbitrary queries in cts:properties-fragment-query() to scope those queries to match only document properties. And, yes, document properties are indexed.