xsl-list
[Top] [All Lists]

Re: [xsl] Problem with "value-of" tags in XSLT to be placed at desired location in Text Output

2006-05-22 13:07:48
there are several changes required in your xslt,
e.g.
       <xsl:template match="inventory/server"> and not
match="domain-name/server"

try the xsl below:

<?xml version="1.0" encoding="UTF-8"?>

<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform";>
      <xsl:output method="text" indent="yes"/>
       <xsl:template match="inventory/server">
 insert into server (

'oracleAppVersion',java-version,java-vendor,java-vm-version,java-vm-vendor,java-vm-name,os-arch,os-name,os-version
) values (
  <xsl:value-of select="comp/weblogic-version"/>,
  <xsl:value-of select="java/version"/>,
  <xsl:value-of select="java/vendor"/>,
  <xsl:value-of select="java/vm/version"/>,
  <xsl:value-of select="java/vm/vendor"/>,
  <xsl:value-of select="java/vm/name"/>,
  <xsl:value-of select="os/arch"/>,
  <xsl:value-of select="os/name"/>,
  <xsl:value-of select="os/version"/>
 );
</xsl:template>
<xsl:template match="jdbc-data">
 insert into jdbc-data (

'oracleAppVersion',java-version,java-vendor,java-vm-version,java-vm-vendor,java-vm-name,os-arch,os-name,os-version
) values (
  <xsl:value-of select="datasource/driver-name"/>,
      <xsl:value-of
select="datasource/database-product-version"/>,
          <xsl:value-of
select="datasource/database-product-name"/>,

 );
</xsl:template>
</xsl:stylesheet>


--

Jagdishwar B.

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--