I think it might be as simple as:
/root/node[@attrib='whatever]/childNodeA/.. So, that selects the <node>s with the attribute you want, then select's their <childNodeA>, and then selects those <childNodeA>'s parents, resulting in a List of <nodes> that match the attribute predicate and have a <childNodeA> Though, the <node> will still have all of its children, include <childNodeB> and <childNodeC> nodes. -bob On Wed, 9 Oct 2002 [EMAIL PROTECTED] wrote: > Good day, > > I'm having alittle trouble here. I can only explain this by example. > So I will try to draw it out as clear as possible. > > <root> > <node attrib=""> > <childNodeA>text</childNode> > <childNodeB>text</childNode> > <childNodeC>text</childNode> > </node> > <node attrib=""> > <childNodeA>text</childNode> > <childNodeB>text</childNode> > <childNodeC>text</childNode> > </node> > ..... > ..... > ..... > </root> > > I would like to search for this query as an example "/root/nodeA/childNodeA" > > Successfully it returns : > > <childNodeA>text</childNode> > <childNodeB>text</childNode> > ..... > ..... > ..... > > Now this is all good, but I need to get parent of each childNode to be > returned > also so I can use the @attrib found in the parent for later use. > > I would a return to looks like this : > > <node attrib=""> > <childNodeA>text</childNode> > </node> > <node attrib=""> > <childNodeB>text</childNode> > </node> > ..... > ..... > ..... > > How would I setup the query to recieve these results. I did trying using > both parent:: and child::, but I either get the parent node along with the > rest > of the child nodes or i end up with the same childNode result without the > parent. Is there any way to resolve this? > > Thank you very much =) > alex > > > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > Jaxen-interest mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jaxen-interest > -- Bob McWhirter [EMAIL PROTECTED] The Werken Company http://werken.com/ ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Jaxen-interest mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jaxen-interest