MJUGRAN 0 Newbie Poster

Hi ,

I am fetching a xml file having n records (destinations one detination may have m routes) as below:

<destination>
    <filename>ABC</filename>
             <route>ftp://manish_test:manish_pass@10.20.21.123:21/%2F1ST-FTP_Poller/dimensionsABC/</route>
    <route>ftp://manish_test:manish_pass@10.20.21.123:21/%2F1ST-FTP_Poller/dimensionsBCD/</route>
</destination>

I have to fetch all these records based on file name (say the above destination for file staring with ABC) and so on...

How I could create xslt to get m variables (m routes) for file starting from ABC and so on ...

What I tried to define m varaible dynamically as below:

  <xsl:template name="get-route-without-message" match="Router">  
    <destinations>
       <xsl:for-each select="destination">
            <destination>
                <xsl:copy-of select="node()"/>
                <xsl:variable name="{concat('url','position()')}" select="concat('route','filename')"/>
            </destination>
      </xsl:for-each>
    </destinations>
  </xsl:template>

Now it is failing with error while creating variable name by concatinating url with position say url1 url2 etc....

Could you please help me out to acheive n varaible for n records....