Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning XSLT and XPath : Transforming XML Documents and Data
This is the forum to discuss the Wrox book Beginning XSLT and XPath : Transforming XML Documents and Data by Ian Williams ISBN: 978-0-470-47725-0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning XSLT and XPath : Transforming XML Documents and Data section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Display Modes
  #1 (permalink)  
Old August 13th, 2014, 06:48 AM
Registered User
Points: 13, Level: 1
Points: 13, Level: 1 Points: 13, Level: 1 Points: 13, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2014
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Need XSLT

Hi All,

I need XSL to translate below input xml into expected output xml.

Req. in brief
I have xml which has item element with attributes itemid and type, i need to segregate those item elements based on its type. Sample input and output is as below.

input
<cat>
<catItem item="1" type="A" />
<catItem item="2" type="A" />
<catItem item="3" type="B" />
<catItem item="4" type="B" />
</cat>
---------------------------------
expected output
<cat>
<Category type="A">
<Item id="1" />
<Item id="2" />
</Category>
<Category type="B">
<Item id="3" />
<Item id="4" />
</Category>
</cat>

Can any one help me to develop XSL for above requirement.

Thanks and Regards,
sbolchetwar
 


Thread Tools
Display Modes

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calling xslt into xslt with different xml file ruchi_doda XSLT 0 February 28th, 2012 07:50 AM
Another question about generating XSLT with XSLT danblick XSLT 2 July 16th, 2009 09:40 PM
General XSLT Questions in the XSLT Forum jminatel BOOK: XSLT 2.0 and XPath 2.0 Programmer's Reference, 4th Edition ISBN: 978-0-470-19274-0 0 March 31st, 2008 08:50 PM
Can XSLT read DTD/schema and Generate XSLT.. ROCXY XSLT 1 November 6th, 2006 09:39 AM
dynamic xslt -> xslt creation namespace problem jkmyoung XSLT 2 July 15th, 2006 01:42 AM



All times are GMT -4. The time now is 03:56 AM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.