<snip> -------------------------------------------------------------- So I want to verify what I already know: that HAIR_LENGTH, FIXATIVE and DIRECTIONAL_TUNING exist in each file, at the same nested depth level.
Attempt #1: xindice xpath -l -c /db/data -q "/XSIL/XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'HAIR_LENGTH']/ancestor::* /XSIL/XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'FIXATIVE']/ancestor::* /XSIL/XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'DIRECTIONAL_TUNING']" ...returns nothing. -------------------------------------------------------------- </snip> As far as my experience goes, knowledge of xpath will lead the way to the correct result. Ok here goes: xindice xpath -l -c /db/data -q "/XSIL[ count(XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'HAIR_LENGTH']) > 0 and count(XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'FIXATIVE']) > 0 and count(XSIL/XSIL/XSIL/XSIL/XSIL/[EMAIL PROTECTED]'DIRECTIONAL_TUNING']) > 0] This doesn't work? Seems more to the point, and more efficient. It looks at only the nodes it is concerned with. In pseudo code: look in collection /db/data and get all XSIL root documents where they all contain at least one element with each of the given attribute values. I simply tried it out on a mock document and it worked, giving me back the correct documents, whereas your query returned to me *every* XSIL node in the document, which would be quite inefficient (if you did get it to work), especially on large collections. I hope this works out for you, let me know, -Kevin Ross -----Original Message----- From: sandy pittendrigh [mailto:[EMAIL PROTECTED] Sent: Monday, June 09, 2003 11:21 AM To: xindice-users@xml.apache.org; sandy pittendrigh Subject: XPath behavior: feature or bug? -- /* Sandy Pittendrigh >--oO0> * [EMAIL PROTECTED] * http://cns.montana.edu/~sandy */