[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Copying nodes problem

Subject: Copying nodes problem
From: "Kanthi Damodaran" <kdsm17@xxxxxxxxxxx>
Date: Wed, 03 Oct 2001 20:04:13 +0000
cdata description
Hello -

I have a problem with copying nodes that I can't figure out. I will reaclly appreciate the help.

Sample XML file :-
<?xml version="1.0"?>
<TOP>
 <filter type="GetIndID">
   <filter type="Initial Table">
	<filter type="BizClass" modifier="OSIND">
	   <filter type="Phrase" modifier="a">
	     <filter type="IndustryInfo">
		<Industry KeyID="1">
		  <Title><![CDATA[Label #1]]></Title>
		  <Description><![CDATA[Description #1]]></Description>
		</Industry>
		<Industry KeyID="220557">
		  <Title><![CDATA[Label #2]]></Title>
		  <Description><![CDATA[Description #2]]></Description>
		</Industry>
		<Industry KeyID="220572">
		  <Title><![CDATA[Label #3]]></Title>
		  <Description><![CDATA[Description #3]]></Description>
		</Industry>
	      </filter>
	   </filter>
	</filter>
    </filter>
  </filter>
</TOP>

Basically I want to copy over all the <filter> tags and manipulate the tags betiween them < > so that the output looks like below -

Desired Output :-
<?xml version="1.0"?>
<TOP>
 <filter type="GetIndID">
   <filter type="Initial Table">
	<filter type="BizClass" modifier="OSIND">
	   <filter type="Phrase" modifier="a">
	     <filter type="IndustryInfo">
              <Industry>
		 <osind>
		  <code>1</code>
		   <label><![CDATA[Label #1]]></label>
		   <description><![CDATA[Description #1]]></description>
		 </osind>
	       </Industry>
		<Industry>
		  <osind>
		   <code>2</code>
		   <label><![CDATA[Label #2]]></label>
		   <description><![CDATA[Description #2]]></description>
		  </osind>
	 	</Industry>
		<Industry>
		  <osind>
		   <code>3</code>
		   <label><![CDATA[Label #3]]></label>
		   <description><![CDATA[Description #3]]></description>
		  </osind>
		</Industry>
            </filter>
	   </filter>
	</filter>
    </filter>
  </filter>
</TOP>

Thanks in advance.
Kanthi

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.