Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries [Thread Prev] >Thread Next - Re: transform multiple input document transform multiple input documentTo: NULL Date: 10/4/2005 6:13:00 PM Dear Experts, Please tell me how can I do the xslt on multiple input file to
one output file.these are the data files.
data.xml
<?xml version="1.0" ?>
<datas>
<data>1</data>
<data>2</data>
<data>3</data>
</datas>
data2.xml
<?xml version="1.0" ?>
<datas>
<data>7</data>
<data>8</data>
<data>9</data>
</datas>
data3.xml
<?xml version="1.0" ?>
<datas>
<data>4</data>
<data>5</data>
<data>6</data>
</datas>
and this is the transform i want to apply to each file
data.xslt
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:output method="xml"/>
<xsl:template match="/">
<items>
<xsl:apply-templates select="datas" />
</items>
</xsl:template>
<xsl:template match="data">
<item>
<xsl:value-of select="."/>
</item>
</xsl:template>
</xsl:stylesheet>
however if i have the list of data files like this
list.xml
<?xml version="1.0" ?>
<files>
<file>data.xml</file>
<file>data2.xml</file>
<file>data3.xml</file>
</files>
how can i do transform each data file and make all output summarized in one
output file like this (please noted that i need to do sorting)output.xml
<?xml version="1.0" encoding="utf-8" ?>
<items>
<item>1</item>
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>
<item>9</item>
</items>Thank for your help.
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
