lookin_vijay Posted June 6, 2006 Share Posted June 6, 2006 can any one help me out how can we sort in xpath.can any one provide an example or some synatax how to sort.Thanks in advancevijay Link to comment Share on other sites More sharing options...
boen_robot Posted June 6, 2006 Share Posted June 6, 2006 Well, you can't. But in XSLT for example, you may use the <xsl:sort> element to sort. There you'll use an XPath expression (most of the times, a single node) to sort by. Other languages also implement their own ways of sorting. The reason for XPath not having sorting is that we are talking the exact same output with only a difference in the order. XPath is for selecting, not presenting. Link to comment Share on other sites More sharing options...
lookin_vijay Posted June 7, 2006 Author Share Posted June 7, 2006 Well, you can't. But in XSLT for example, you may use the <xsl:sort> element to sort. There you'll use an XPath expression (most of the times, a single node) to sort by. Other languages also implement their own ways of sorting. The reason for XPath not having sorting is that we are talking the exact same output with only a difference in the order. XPath is for selecting, not presenting.<{POST_SNAPBACK}> Thankyou verymuch for the promt reply Link to comment Share on other sites More sharing options...
kgw Posted August 8, 2006 Share Posted August 8, 2006 Actually if you want to sort, you can use XQuery - order by Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now