On 17.Apr.2002 -- 09:10 AM, Jerzy Kut wrote:
> Hi cocooners!
> I know that esql:get-row-count is unavailable yet. But I need to get this
> information from my DB.
> I try:
 
>    <batch:element-count><dbman:employees-count/></batch:element-count>

> batch.xsl
>  <xsl:template match="batch:navigator">
>   <xsl:param name="element-count" select="batch:element-count"/>

>      (Long.parseLong(<xsl:value-of select="$element-count"/>) - 1) /

OK, this is no briliant analysis of your code and certainly will not
readily solve your problem, however, you have an XSL problem here:

The last line is going to be expanded to something like

 (Long.parseLong(<count><esql:connection><esql:query>.....</esql:connection></count>)-1

which certainly was not your intention.

If you pass parameters this way, make sure that your templates really
expand to a single text node (in the end). This is not like calling
functions but programming with macros. Bear that in mind!

You might want to use java beans to communicate.

Anyway, this is not a trivial problem and I bet most new-comers hit
this wall at some time.

        Chris.

-- 
C h r i s t i a n       H a u l
[EMAIL PROTECTED]
    fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to