You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Roger I Martin PhD <hy...@hypernexinc.com> on 2001/10/25 15:00:27 UTC
esql logicsheet get-column-name column=?
Hello,
I am new to Cocoon. Using version 2.
I am trying to use the esql:get-column-name template and am having difficulty supplying the numerical index.
<esql:get-column-name column="1"/>
causes
java.lang.NumberFormatException: sun.tools.javac.Main has been deprecated.
Also I want to supply an index variable like
<xsp:logic>
for(int _esql_i=1;_esql_i<=<esql:get-column-count/>;_esql_i++)
{
</xsp:logic>
<th>
<xsp:logic>
<esql:get-column-name column="_esql_i"/>
</xsp:logic>
</th>
<xsp:logic>
}
</xsp:logic>
How?
Thanks. I want to get my stuff going and also want to build some examples to put with the http://xml.apache.org/cocoon2/logicsheet-esql.html page.
Roger
Re: esql logicsheet get-column-name column=?
Posted by Christian Haul <ha...@dvs1.informatik.tu-darmstadt.de>.
On 07.Nov.2001 -- 07:56 AM, Roger I Martin PhD wrote:
> Apparently esql:get-column-name takes only column names and string representation of column indexes; no variables. The generated java code shows either
> although it looks like it should be feasible. Is there a way?
>
> Also I want to supply an index variable like
>
> <xsp:logic>
> for(int _esql_i=1;_esql_i<=<esql:get-column-count/>;_esql_i++)
> {
> </xsp:logic>
> <th>
> <xsp:logic>
> <esql:get-column-name column="_esql_i"/>
> </xsp:logic>
> </th>
> <xsp:logic>
> }
> </xsp:logic>
>
> How?
You might have found out by now, if not, you'd need to
<esql:get-column-name><esql:param name="column"><xsp:expr>_esql_i</xsp:expr></esql:param></esql:get-column>
Sorry, for such a late response.
Chris.
--
C h r i s t i a n H a u l
haul@informatik.tu-darmstadt.de
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: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>
Re: esql logicsheet get-column-name column=?
Posted by Roger I Martin PhD <hy...@hypernexinc.com>.
Apparently esql:get-column-name takes only column names and string representation of column indexes; no variables. The generated java code shows either
XSPObjectHelper.xspExpr( contentHandler,
_esql_query.getResultSet().
getMetaData().getColumnName(3));
or
XSPObjectHelper.xspExpr( contentHandler,
_esql_query.getResultSet().
getMetaData().getColumnName("_esql_i"));
but I can never get
XSPObjectHelper.xspExpr( contentHandler,
_esql_query.getResultSet().
getMetaData().getColumnName(_esql_i));
although it looks like it should be feasible. Is there a way?
Roger
----- Original Message -----
From: Roger I Martin PhD
To: cocoon-users@xml.apache.org
Sent: Thursday, October 25, 2001 8:00 AM
Subject: esql logicsheet get-column-name column=?
Hello,
I am new to Cocoon. Using version 2.
I am trying to use the esql:get-column-name template and am having difficulty supplying the numerical index.
<esql:get-column-name column="1"/>
causes
java.lang.NumberFormatException: sun.tools.javac.Main has been deprecated.
Also I want to supply an index variable like
<xsp:logic>
for(int _esql_i=1;_esql_i<=<esql:get-column-count/>;_esql_i++)
{
</xsp:logic>
<th>
<xsp:logic>
<esql:get-column-name column="_esql_i"/>
</xsp:logic>
</th>
<xsp:logic>
}
</xsp:logic>
How?
Thanks. I want to get my stuff going and also want to build some examples to put with the http://xml.apache.org/cocoon2/logicsheet-esql.html page.
Roger