# Xpath sorting

**URL:** <https://forum.kirupa.com/t/xpath-sorting/183344>\
**Category:** Uncategorized\
**Created:** [March 26, 2006, 1:41am UTC](https://forum.kirupa.com/t/xpath-sorting/183344 "2006-03-26T01:41:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tristessa](https://avatars.discourse-cdn.com/v4/letter/t/a88e4f/32.png) [@tristessa](https://forum.kirupa.com/u/tristessa)\
**Post date:** [March 26, 2006, 1:41am UTC](https://forum.kirupa.com/t/xpath-sorting/183344/1 "2006-03-26T01:41:29Z")

</div>

👁 hi all again

still working on a sort system in flash, i am fiddling around in xpath

yet, i stumble on an issue

lets say my xml is :

```auto

<xml>
<item client ="tolkien" id="1" work="whatever"etc etc </item>
<item client ="tolkien" id="1" work="whatever"etc etc </item>
<item client ="kirupa" id="2" work="whatever"etc etc </item>
 </xml>

```

as you can see, i have 2 items for tolkien(which are responsible for 2 different works), 1 for kirupa (only 1 job)

now i want to show a list for al the clients, tough, i only want to show up  
1 unique identity for every client  
so in this case the output would be

found clients :  
tolkien  
kirupa

here is how i sort the clients with the mighty xpath  
still it’s outputwould be  
tolkien  
tolkien  
kirupa

```auto

path = "/xml/item[@client]";
          client_array = mx.xpath.XPathAPI.selectNodeList(this.firstChild, path);

```

i hope this is , thanx in advance if anyone could help me out

---

<div class="post-metadata">

**Author:** ![tristessa](https://avatars.discourse-cdn.com/v4/letter/t/a88e4f/32.png) [@tristessa](https://forum.kirupa.com/u/tristessa)\
**Post date:** [March 26, 2006, 7:35pm UTC](https://forum.kirupa.com/t/xpath-sorting/183344/2 "2006-03-26T19:35:49Z")

</div>

bump, plz anyone can point me towards something?  
:p:
