cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Donald Ball <>
Subject Re: newlines in a query using SQL taglib
Date Fri, 23 Jun 2000 15:02:10 GMT
On Fri, 23 Jun 2000, Andy Bowles wrote:

> I'm trying to write some XSLT/XSP pages to construct a tagset for the
> SQL taglib package (all in Cocoon 1.7), so I have a tag like this:
>  <sql:execute-query> 
>    ...
>    <sql:query>
>      ... tags to construct a SELECT from other parts of the document ...
>    </sql:query>
>  </sql:execute-query> 
> Things worked as expected, until the SELECT construction started
> spreading over several lines, when I started getting Java compile errors
> "String not terminated at end of line".  Java doesn't allow string
> literals over a line break, which is what is getting generated.
> I think possible solutions to this include:
> - write all my tags on one line, and go cross-eyed.
> - use some nifty bit of XSL to get rid of the newlines.
> - hack the SQL taglib to remove them for me.

i had asked ricardo how to deal with this but hadn't gotten a response
yet. i suspect you could do something clever in the get-nested-string
template in sql.xsl to strip newlines and carriage returns. worst comes to
worst, i could strip the characters in the java library, but i'd prefer to
do that higher up on the food chain.

- donald

View raw message