kdm06
kdm06

Reputation: 189

MarkLogic - How can you do a collection-delete using Java API?

How can you do a collection-delete using Java API? I'm using a JSONDocumentManager for my CRUD operations. Is there a way to do something like:

xdmp:collection-delete("myCollection")

Upvotes: 4

Views: 364

Answers (1)

John Smith
John Smith

Reputation: 1579

Use the QueryManager.delete() passing it a QueryManager.newDeleteDefinition() and in the DeleteQueryDefinition set the list of collections which you want to have deleted.

Upvotes: 3

Related Questions