You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Pål Wester <pa...@never.no> on 2001/03/24 02:22:00 UTC

is there any way i can know tha columnnames in esql??

Wheres the problem:

I'm making a pushingsystem which has custom-documents.
these consists of 5 known fields and a an unknown other
fields.

Is there any way to access the field-names after
executing a query?
mvh: Pål Wester
høgskoleingenør/programmerer


never.no as, stortingsgt 30, 0161 Oslo
direkte: 22 01 66 34, 906 900 62
tlf: 22 01 66 34, fax: 22 01 66 21
http://never.no - icq:103476059





Re: SV: is there any way i can know tha columnnames in esql??

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 26 Mar 2001, [iso-8859-1] P�l Wester wrote:

> Something like this then:
>
> <xspdoc:desc>returns the number of columns in the resultset.</xspdoc:desc>
> <xsl:template match="esql:row-results//esql:get-column-count">
>   <xsp:expr><xsl:call-template
> name="get-resultset"/>.getMetaData().getColumnCount()</xsp:expr>
> </xsl:template>

just about, yeah. only diff is that esql:get-column-count is allowed
anywhere underneath esql:results, not just inside the esql:row-results
element. anyway, i finally got around to checking some stuff into cvs,
this included.

- donald


---------------------------------------------------------------------
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>


SV: is there any way i can know tha columnnames in esql??

Posted by Pål Wester <pa...@florence.never.no>.
Something like this then:

<xspdoc:desc>returns the number of columns in the resultset.</xspdoc:desc>
<xsl:template match="esql:row-results//esql:get-column-count">
  <xsp:expr><xsl:call-template
name="get-resultset"/>.getMetaData().getColumnCount()</xsp:expr>
</xsl:template>


mvh: Pål Wester <ma...@never.no>
høgskoleingenør/programmerer

> -----Opprinnelig melding-----
> Fra: Donald Ball [mailto:balld@webslingerZ.com]
> Sendt: 26. mars 2001 07:18
> Til: Cocoon
> Emne: Re: is there any way i can know tha columnnames in esql??
>
>
> On Sat, 24 Mar 2001, [iso-8859-1] Pål Wester wrote:
>
> > Heres the problem:
> >
> > I'm making a pushingsystem which has custom-documents.
> > these consists of 5 known fields and a an unknown other
> > fields.
> >
> > Is there any way to access the field-names after
> > executing a query?
>
> that'd be metadata stuff:
>
> <xsl:template match="esql:row-results//esql:get-column-name">
>   <xsp:expr><xsl:call-template
> name="get-resultset"/>.getMetaData().getColumnName(<xsl:value-of
> select="@column"/>)</xsp:expr>
> </xsl:template>
>
> ta-da. well, i guess we need to add a template for getColumnCount as wel
> tho...
>
> - donald
>
>
> ---------------------------------------------------------------------
> 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>


---------------------------------------------------------------------
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: is there any way i can know tha columnnames in esql??

Posted by Donald Ball <ba...@webslingerZ.com>.
On Sat, 24 Mar 2001, [iso-8859-1] P�l Wester wrote:

> Wheres the problem:
>
> I'm making a pushingsystem which has custom-documents.
> these consists of 5 known fields and a an unknown other
> fields.
>
> Is there any way to access the field-names after
> executing a query?

that'd be metadata stuff:

<xsl:template match="esql:row-results//esql:get-column-name">
  <xsp:expr><xsl:call-template
name="get-resultset"/>.getMetaData().getColumnName(<xsl:value-of
select="@column"/>)</xsp:expr>
</xsl:template>

ta-da. well, i guess we need to add a template for getColumnCount as wel
tho...

- donald


---------------------------------------------------------------------
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>