Re: [xsl] (simple?) xpath question

Subject: Re: [xsl] (simple?) xpath question
From: mark bordelon <markcbordelon@xxxxxxxxx>
Date: Fri, 29 Aug 2008 13:09:43 -0700 (PDT)
mozer:

Entering your zpath query into xpath window in XMLspy yields no results. Is this an Altova bug?

mark


--- On Fri, 8/29/08, mozer <xmlizer@xxxxxxxxx> wrote:

> From: mozer <xmlizer@xxxxxxxxx>
> Subject: Re: [xsl] (simple?) xpath question
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Date: Friday, August 29, 2008, 1:00 PM
> Mark,
> 
> //*[name() = 'a' or name() = 'c']
> 
> is the right syntax
> 
> Xmlizer
> 
> On Fri, Aug 29, 2008 at 9:57 PM, mark bordelon
> <markcbordelon@xxxxxxxxx> wrote:
> > Thanks, Colin,
> >
> >
> > Although the requirements cannot assume how many
> levels there are between the root node and the desired node,
> your solution points me to something like this. Does this
> work?
> >
> >
> > //[name() == "a" and name() ==
> "c"]
> >
> >
> >
> >
> > --- On Fri, 8/29/08, Colin Paul Adams
> <colin@xxxxxxxxxxxxxxxxxx> wrote:
> >
> >> From: Colin Paul Adams
> <colin@xxxxxxxxxxxxxxxxxx>
> >> Subject: Re: [xsl] (simple?) xpath question
> >> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> >> Date: Friday, August 29, 2008, 12:22 PM
> >> >>>>> "Mark" == mark
> bordelon
> >> <markcbordelon@xxxxxxxxx> writes:
> >>
> >>     Mark> All *help*!    What is the best way
> to query
> >> xml with xpath
> >>     Mark> to get a disjoint nodelist?
> Specifically i
> >> want to include
> >>     Mark> just the root node alongwith a
> descendent
> >> node.    XML:
> >>     Mark> <a>   <b>     <c>
> >> </c>  </b> </a>   XPATH:   //c
> >>     Mark> DESIRED RESULT NODELIST: i.e. not
> this:
> >> <c> </c>   but
> >>     Mark> rather this: <a>   <c>
> >> </c> </a>
> >>
> >> One possibility is:
> >>
> >> //*[name() != "b"]
> >>
> >> It depends on your exact requirements.
> >> --
> >> Colin Adams
> >> Preston Lancashire

Current Thread