[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Problem regarding getting complete Node with value

Subject: Re: Problem regarding getting complete Node with value
From: "Vasu Chakkera" <vasucv@xxxxxxxxxxx>
Date: Wed, 28 Aug 2002 07:31:22 +0000
java xml node value
Mukul,
the following code will help you

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
xmlns:java="http://xml.apache.org/xslt/java"
exclude-result-prefixes="java">
<xsl:output method="xml" indent="yes"/>
<xsl:output encoding="ISO-8859-1"/>
<xsl:template match="DataSet">
<AccountDetails>
<xsl:copy-of select="node()"/>
</AccountDetails>
</xsl:template>
</xsl:stylesheet>

cheers
Vasu

From: Mukul.Mudgal@xxxxxxxxxxx
Reply-To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
To: XSL-List@xxxxxxxxxxxxxxxxxxxxxx
Subject:  Problem regarding getting complete Node with value
Date: Wed, 28 Aug 2002 12:04:44 +0530

Hi friends

I'm try to convert this

<DataSet XslFileName="AccountOpen.xsl">
      <SortCode Value="000002"/>
      <AccountNumber Value="123456789"/>
      <BranchCodeOrig Value="127"/>
      <ProductCode Value="101010"/>
      <JointMandate Value = "E"/>
      <OpenDate Value="0020730"/>
      <ACCRINTDATELAST Value="20020730" />
      <Balance Value="10"/>
</DataSet>

in to this
<AccountDetails>
      <SortCode Value="000002"/>
      <AccountNumber Value="123456789"/>
      <BranchCodeOrig Value="127"/>
      <ProductCode Value="101010"/>
      <JointMandate Value = "E"/>
      <OpenDate Value="0020730"/>
      <ACCRINTDATELAST Value="20020730" />
      <Balance Value="10"/>
</AccountDetails>

I'm using this xsl file

<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
xmlns:java="http://xml.apache.org/xslt/java"
exclude-result-prefixes="java">
<xsl:output method="xml" indent="yes"/>
<xsl:output encoding="ISO-8859-1"/>
<xsl:strip-space elements="*"/>
<xsl:template match="*">
            <AccountDetails>
<xsl:copy-of select="DataSet" />
      </AccountDetails>
      </xsl:template>
</xsl:stylesheet>

But after transformation it gives

<?xml version="1.0" encoding="ISO-8859-1"?>
<AccountDetails>
    <DataSet XslFileName="AccountOpen.xsl">
      <SortCode Value="000002"/>
      <AccountNumber Value="123456789"/>
      <BranchCodeOrig Value="127"/>
      <ProductCode Value="101010"/>
      <JointMandate Value="E"/>
      <OpenDate Value="0020730"/>
      <ACCRINTDATELAST Value="20020730"/>
      <Balance Value="10"/>
</DataSet>
</AccountDetails>

though above result is correct but I don't want the <DataSet/>  node. As
I've mentioned above in the required result file.

how could I get the required result,?? Please help....

Thanks
Mukul





XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list




_________________________________________________________________
MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx



XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.