As a first step, try putting the predicate at the end of your XPath
expression.  Something like this:

fn:collection()/doc/item/classification/[EMAIL PROTECTED] = "class1"]

Does that help? 

-Danny

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Steve
Sent: Wednesday, October 29, 2008 7:02 AM
To: [email protected]
Subject: [MarkLogic Dev General] Improving Lookup Performance

Folks,

I've got a MarkLogic instance running with approximately 100,000
documents in it (this needs to scale to approximately 2.5 million),
and I'm doing some basic lookups etc.

I've been executing queries such as those shown below, however the
results are taking a long time to come back. I've got indexes against
the elements and attributes that I'm trying to lookup, however I'm
looking for other ways to improve performance of queries. Anybody got
any suggestions??

example queries

fn:collection()[/doc/item/classification/@value = "class1"]

fn:colleciton()[//classification/@value = "class1"]

fn:distinct-values(fn:collection()[/doc/item/name])
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to