xsl-list
[Top] [All Lists]

RE: XPATH: how to get position of child-elementTAG ? (order of elemenTAGs, not of element)

2005-08-16 04:10:53
 

-----Original Message-----
From: Jule Kleine [mailto:listmail(_at_)web(_dot_)de] 
Sent: Tuesday, August 16, 2005 4:20 PM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] XPATH: how to get position of child-elementTAG ? (order of 
elemenTAGs, not of element)


Hi,

I would like to check, if the name of the second element of root is 
"youngestSon". Is it possible to query this with xpath (I use xquery with 
xpath-expressions, in fact I already know the name of the element but want to 
get sure with an exist-statement, that the element's position is 2) ?

<parent>
<oldestSon>A</oldestSon>
<youngestSon>B</youngestSon>
</parent>

Note, that the child element names are different. What I dont need is the 
second son in the following example (therefor I could use 
/parent/son[position()==2] )

<parent>
<son>A</son>
<son>B</son>
</parent>

Thank you for any help!
Jule
_________________________________________________________________________
Mit der Gruppen-SMS von WEB.DE FreeMail können Sie eine SMS an alle Freunde 
gleichzeitig schicken: http://freemail.web.de/features/?mc=021179




--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>