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

RE: Counting records [Solved] - addendum

Subject: RE: Counting records [Solved] - addendum
From: "Bradley, Peter" <pbradley@xxxxxxxxxx>
Date: Tue, 9 Dec 2008 12:47:58 -0000
RE:  Counting records [Solved] - addendum
Apologies.  It's the stylesheet I can't change - or even access.  It's
constructed implicitly using the XPath expression I give it.  Unless I
give it the one I mentioned, it won't work.

What I'm doing is giving BizTalk the XPath expression needed for it to
perform a transformation for me and output a result containing the
rowcount.

But never mind.  The answers you all provided me with pointed me in the
right direction so that I could then sort BizTalk out.  So I'm grateful
for that.

Cheers


Peter


-----Original Message-----
From: Martin Honnen [mailto:Martin.Honnen@xxxxxx]
Sent: 09 December 2008 11:35
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  Counting records [Solved] - addendum

Bradley, Peter wrote:
> Because that's what BizTalk requires.

I don't know BizTalk but you said it requires that saying "where I
have no control over the XML being used". However the solutions
suggested to you did not ask you to change the XML, the simply suggested

to change the stylesheet to e.g.

<xsl:stylesheet
     xmlns:df="http://HesaValidateSqlSend"
     xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     version="1.0">

     <xsl:template match="/">
       <xsl:value-of select="count(/df:HesaValidate_Response/df:row)"/>

If you can change the stylesheet in BizTalk to use the cumbersome

count(/*[local-name()='HesaValidate_Response' and
namespace-uri()='http://HesaValidateSqlSend']/*[local-name()='row' and
namespace-uri()='http://HesaValidateSqlSend'])

why can't you change it as suggested? Both are changes to the stylesheet

only.

You do not even need to put the namespace declaration on the
xsl:stylesheet element if you can't change that, doing


<xsl:stylesheet
     xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     version="1.0">

     <xsl:template match="/">
       <xsl:value-of xmlns:df="http://HesaValidateSqlSend"
                     select="count(/df:HesaValidate_Response/df:row)"/>

would suffice as well.


--

	Martin Honnen
	http://JavaScript.FAQTs.com/

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.