-
Sort xml using xsl (unknown input type (text/numbers mixed) with/without tokens)
Hi i have xml file with nodes that could hold any type of input, for example:
XML code:
<Employees>
<Employee>
<Code>1.2.3</Code>
<name>John</name>
</Employee>
<Employee>
<Code>2.3.9</Code>
<name>John</name>
</Employee>
<Employee>
<Code>2.3.8</Code>
<name>John</name>
</Employee>
<Employee>
<Code>a</Code>
<name>John</name>
</Employee>
<Employee>
<Code>z</Code>
<name>John</name>
</Employee>
<Employee>
<Code>11.2.4</Code>
<name>John</name>
</Employee>
<Employee>
<Code>2.3.7</Code>
<name>John</name>
</Employee>
<Employee>
<Code>d.1.5</Code>
<name>John</name>
</Employee>
<Employee>
<Code>a.2.1</Code>
<name>John</name>
</Employee>
<Employee>
<Code>c.4.2</Code>
<name>John</name>
</Employee>
<Employee>
<Code>d.1.5</Code>
<name>John</name>
</Employee>
<Employee>
<Code>a.2.1.3</Code>
<name>John</name>
</Employee>
<Employee>
<Code>c.4.2.7</Code>
<name>John</name>
</Employee>
<Employee>
<Code>a.2.1.1</Code>
<name>John</name>
</Employee>
<Employee>
<Code>c.4.2.2</Code>
<name>John</name>
</Employee>
<Employee>
<Code>c.4.2.7</Code>
<name>John</name>
</Employee>
<Employee>
<Code>e</Code>
<name>John</name>
</Employee>
<Employee>
<Code>g</Code>
<name>John</name>
</Employee>
</Employees>
The problem is that i can get any type of input in the code node and i don't know the amount of tokens between the data (or there might be no tokens_
it could be a.b.c and it could be a.b.c.d or only a and only b (letters only) or 1 only and 8 only or 8.2.a (chars mixed with numbers).
Im looking for a way to sort the input and compare each token based on its type...(numbers or text)
How can i do it (or how can i do the sort with other method???)
i need to sort with xslt (xsl file)
Thanks ahead
Daniel
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
|
Bookmarks