Search code examples
marklogicmarklogic-9

Not able to see xquery result in qconsole while CRUD operation is going on using MarkLogic Java API


I have a scenario in which we are doing multiple CRUD operations on available documents in specific collection and simultaneously we are pulling data from that specific collection to show it on UI.

For Example - lets assume I have a collection called Inventory and I am updating(Doing CRUD Operation) on multiple documents available in Inventory collection using JAVA api and simultaneously I am pulling data from Inventory collection using XQuery to show it on UI but when JAVA api is performing CRUD operation at that time I am not able to get the xquery result.


Solution

  • Your query will not show those changes until the update commits. That's by design. If you're saying that you have updates that have been committed and you're not seeing those, perhaps it's because your query started before the updated committed.

    Relevant reference: Understanding Transactions in MarkLogic Server