Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > dynmaic recursive nesting in xsl?

Reply
Thread Tools

dynmaic recursive nesting in xsl?

 
 
Elhanan
Guest
Posts: n/a
 
      05-17-2006
hi..

i have the following xml document
<CaseRisk Id="0102" ResultLevelId="1" />

<CaseRisk Id="01030102" ResultLevelId="5">

<CaseRisk Id="010305" ResultLevelId="5">

<CaseRisk Id="0103" ResultLevelId="1">


<CaseRisk Id="0101" ResultLevelId="1">

etc..

into to come up with xsl that will each CaseRisk with another, now the
nesting rules are that Each CaseRisk that it's Id has another CaseRisks
Id init ,is nested inside that CaseRisk:

for example id 010305 should be nested inside id 0103 and 01030102
should be nested inside 010305

problems is that i don't the exact depth of each nest level, my only
solution would be to first select the shorest id's there are, for each
one, try to find id that contain that id in the outloop but are longer
by 2 digits , if i can't find any go to another depth and start
scanning for longer id's, untill i reach the length longest id that
exists in that xml
is that possible with xsl?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Recursive functions Vs Non-recursive functions - performance aspect vamsi C Programming 21 03-09-2009 10:53 PM
dynmaic allocation Jung, William C++ 3 11-20-2008 08:33 AM
Two recursive calls inside of a recursive function n00m C++ 12 03-13-2008 03:18 PM
Module.nesting -> Kernel#nesting Trans Ruby 10 09-16-2005 12:21 AM
group nesting David K MCSE 6 12-12-2003 04:54 PM



Advertisments