Do the elements in question have a namespace? If so, you will need to provide 
it in the element-attribute range configuration of the admin console as well as 
in the options of the query. Also, does the collation specified in the admin 
console match the collation you specify below (http://marklogic.com/collation/)?

From: [email protected] 
[mailto:[email protected]] On Behalf Of Curtis Wilde
Sent: Monday, March 28, 2011 4:30 PM
To: General Mark Logic Developer Discussion
Subject: [MarkLogic Dev General] XDMP-ELEMATTRRIDXNOTFOUND Even when index is 
present.

I'm trying to perform a search, and I know I have an index in place (see 
below), but it returns an exception saying that the index is not found.

This also happens after re-indexing my database.

Windows 7x64, MarkLogic 4.2-3.2

<range-element-attribute-index 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns="http://marklogic.com/xdmp/database";>

  <scalar-type>string</scalar-type>

  <parent-namespace-uri/>

  <parent-localname>book chapter letter attachment magazine section article 
subArticle figureBlock topicBlock formBlock tocBlock tocEntry</parent-localname>

  <namespace-uri/>

  <localname>fileID</localname>

  <collation>http://marklogic.com/collation/</collation>

  <range-value-positions>false</range-value-positions>

</range-element-attribute-index>



let $uri := "/myfile.xml"

return cts:element-attribute-values( xs:QName("article"), xs:QName("fileID"), 
cts:element-query( xs:QName( "article" ), cts:document-query( $uri) ) )



[1.0-ml] XDMP-ELEMATTRRIDXNOTFOUND: cts:element-attribute-values(fn:QName("", 
"article"), fn:QName("", "fileID"), cts:element-query(fn:QName("", "article"), 
cts:document-query("/myfile.xml"), ())) -- No element-attribute range index for 
fn:QName("", "article") fn:QName("", "fileID") http://marklogic.com/collation/



 NOTICE: This email message is for the sole use of the intended recipient(s) 
and may contain confidential and privileged information. Any unauthorized 
review, use, disclosure or distribution is prohibited. If you are not the 
intended recipient, please contact the sender by reply email and destroy all 
copies of the original message.


_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to