Big Bansal
Big Bansal

Reputation: 73

Print the Marklogic Search Query

How can I print the complete query which is being executed in MarkLogic?

val jsonDocManager = dbClient.newJSONDocumentManager()
var newDocPage = jsonDocManager.search(queryDef, 20)

Upvotes: 0

Views: 43

Answers (1)

ehennum
ehennum

Reputation: 7335

You can set the query options in the query definition and, in the query options, set the debug option to true. See:

http://docs.marklogic.com/guide/search-dev/appendixa#id_68047

Hoping that helps,

Upvotes: 2

Related Questions