Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > Reading output xml in the same XSLT, which perform the transformation

Reply
Thread Tools

Reading output xml in the same XSLT, which perform the transformation

 
 
titusjava@yahoo.com
Guest
Posts: n/a
 
      05-19-2005
I am having a XSLT which transforms an input XML to transformed XML.
I want to get the count of some nodes in the transformed XML, in the
same XSLT.
Is it do able?. Is it possible to read Output XML, in the same XSLT
which perform the transformation.

 
Reply With Quote
 
 
 
 
Martin Honnen
Guest
Posts: n/a
 
      05-19-2005


http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:

> I am having a XSLT which transforms an input XML to transformed XML.
> I want to get the count of some nodes in the transformed XML, in the
> same XSLT.
> Is it do able?. Is it possible to read Output XML, in the same XSLT
> which perform the transformation.


Only with an extension function which converts a result tree fragment to
a nodeset. You would store the result tree fragment in a variable and
then use
count(exsl:node-set($variable))
see
<http://www.exslt.org/exsl/functions/node-set/index.html>

--

Martin Honnen
http://JavaScript.FAQTs.com/
 
Reply With Quote
 
 
 
 
Dimitre Novatchev
Guest
Posts: n/a
 
      05-19-2005
No xxx:node-set() extension function is necessary in XSLT 2.0 as there's no
RTF type there.

Cheers,
Dimitre Novatchev

"Martin Honnen" <(E-Mail Removed)> wrote in message
news:428cb0d0$0$25679$(E-Mail Removed)-online.net...
>
>
> (E-Mail Removed) wrote:
>
>> I am having a XSLT which transforms an input XML to transformed XML.
>> I want to get the count of some nodes in the transformed XML, in the
>> same XSLT.
>> Is it do able?. Is it possible to read Output XML, in the same XSLT
>> which perform the transformation.

>
> Only with an extension function which converts a result tree fragment to a
> nodeset. You would store the result tree fragment in a variable and then
> use
> count(exsl:node-set($variable))
> see
> <http://www.exslt.org/exsl/functions/node-set/index.html>
>
> --
>
> Martin Honnen
> http://JavaScript.FAQTs.com/



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
XML to another XML format transformation using XSLT Binaryx XML 3 04-14-2012 10:20 PM
questions and recommend books about refactoring of xml-schematas and the transformation of xml-documents HL XML 2 10-20-2006 04:41 PM
no tags in my xml-to-xml transformation, help.... yannicklaclau XML 2 02-28-2005 03:44 PM
Any problems with writing the information into a file - Multi-users perform writing the same file at the same time ???? HNguyen ASP .Net 4 12-21-2004 01:53 PM
XML to XML Transformation Will XML 8 11-07-2003 05:05 PM



Advertisments