Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

XSL Transformation help needed (original and new provided)

AnatoliAnatoli Posts: 2Member
Hi all,

I am to this forum and new to XSL. I am working on a generic reporting solution. XSL is the stumbling block.
I need to create an XSL stylesheet that converts ANY(!) XML created by .Net DataSet object into an XML file,
which can be diplayed in a web page using another stylesheet.

The DataSet can have results from multiple (!) queries.
The very first one unnamed SQL creates node with the column names as children where text has the data.
Every new SQL creates Table1, Table2, etc. I need to convert all queries into headers with column names and rows with data.

Original:

<?xml version="1.0" standalone="yes"?>


25.7500

45.15


2005-04-13T23:02:38.6270000+10:00


23


43


Testing Output


172-32-1176
White
Johnson
408 496-7223
10932 Bigge Rd.
Menlo Park
CA
94025
true


213-46-8915
Green
Marjorie
415 986-7020
309 63rd St. #411
Oakland
CA
94618
true



New, comments are not necessary, they are for readability only

<?xml version="1.0" standalone="yes"?>
<?xml-stylesheet type="text/xsl" href="datasetstylesheet.xsl" ?>




Column1


25.7500




Test_x0020_Decimal


45.15




Today


2005-04-13T23:02:38.6270000+10:00




Num_x0020_of_x0020_Authors


23




Num_x0020_of_x0020_Employees


43




Column1


Testing Output




au_id
au_lname
au_fname
phone
address
city
state
zip
contract


172-32-1176
White
Johnson
408 496-7223
10932 Bigge Rd.
Menlo Park
CA
94025
true


213-46-8915
Green
Marjorie
415 986-7020
309 63rd St. #411
Oakland
CA
94618
false




Your help is appreciated!
Anatoli

If you need more info, please post here.

Sign In or Register to comment.