Better keep the discussion on list...

Use the xml-serializer instead of html, like
<map:serialize type="xml"/>.

You can just paste that right after the sql-transformer in the pipeline, since it will stop execution at that point (no need to remove xsl-transformer and html-serializer)

Another option is to use the log-transformer, like
<map:transform type="log"/>

Askild
-

Oleg Konovalov wrote:

Askild,

And how can I see that output (in XML form)?

If I just remove XSLT transformer (have HTML serializer),
I get resulting data (no XML).
I tried to download and apply simple-sql2html.xsl
stylesheet from here:
http://fisheye.cenqua.com/changelog/xml?cs=MAIN:giacomo:20010509204926
but it's not complete [xsl not defined, etc.], but when I
resolved that, getting the same data as without it, no XML.

So how can I get XML output from SQL transformer ?

TIA,
Oleg.


--- Askild Aaberg Olsen <[EMAIL PROTECTED]> wrote:

Oleg Konovalov wrote:

Ard,

I've read a lot of Cocoon documentation on the net and books,
especially regarding SQL Transformer. It does mention that queries might be named.
So if I have several SQL queries in SQLTransformer (e.g.
query1,
query2), what is a convention for the output ?

<page xmlns:sql="http://apache.org/cocoon/SQL/2.0";> <content>
<sql:execute-query>
<sql:query name="query1"> SELECT * FROM custtable WHERE cust_id=<sql:substitute-value sql:name="cust_id"/>
</sql:query>
</sql:execute-query>
...
</content>
</page>

I need to pickup this SQLTransformer output (few rowsets) as
an
input into XSLT->HTML transformer/serializer,
something like:

<xsl:variable name='rowset1'
select='/page/content/paging/data/query1'/> ?


It adds an attribute named "name" to the rowset, like:

<xsl:value-of

select="/sqlpart/sql:[EMAIL PROTECTED]'query1']/sql:row/sql:thisfield"/>
I'm not 100% sure this is the right output (just looked in SQLTransformer.java) , but why don't you just look at the
pipeline output?

Askild
-


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






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