Hi Shannon,
You can do a wildcarded search to find that. Something like:
let $query := cts:element-attribute-word-query(xs:QName("div"),
xs:QName("xml:id"), "Dia*", "wildcarded")
let $node := <div xml:id="Dia01ch10m4.5"/>
return
cts:contains($node, $query)
Adding some wildcard indexes will improve the performance of wildcard
queries in a cts:search and in XPath statements.
-Danny
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Shannon
Sent: Friday, November 14, 2008 9:42 AM
To: General Mark Logic Developer Discussion
Subject: [MarkLogic Dev General] cts:element-attribute-contains-query?
or*word-query option? or regex please?
hi,
cts:element-attribute-value-query is for "content equal a given
phrase" and cts:element-attribute-word-query is for "content
containing a given phrase", but i'm looking for a cts:query
constructor that matches a substring, e.g., given <div
xml:id="Dia01ch10m4.5"> I want to match on "Dia" -- any suggestions
you have would be most helpful. i think we have workarounds for the
limitation, but can it be done, out of curiosity? If no, please
consider this a feature request :)
thanks,
__________________________________________________
Shannon Scott Shiflett, programmer/analyst with ROTUNDA,
The University of Virginia Press, Charlottesville, VA USA
http://rotunda.upress.virginia.edu
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general