[MarkLogic Dev General] Struggling with Query Time Out

Betty Harvey harvey at eccnet.com
Fri Mar 16 12:17:12 PDT 2012

I have been unable to get this query to run successfully without timing
out.  To make sure my logic was correct I placed 100 documents in the
'documents' database and query runs successfully and very quickly. In the
large database 1.7 million objects the query always times out.

I am not sure cts:search will help.  I played around with it without
success.   The goal of the query is to gather information for a particular
month based on when the document was created.   Below is the code:

for $ACE in xdmp:directory('opt/MOR/ACE/')/descendant::ACE
   [EventSet/GeneralEvent[1]/EventDate gt '2011-03-01T00:00:00']
   [EventSet/era:GeneralEvent[1]/EventDate lt '2011-04-01T00:00:00']
let $ACEId := $ACE/ACEId
let $EventDate := $ACE/EventSet/era:GeneralEvent[1]/era:EventDate

Any ideas are appreciated!


More information about the General mailing list