display sql:query

From: Andreas Bauer (buki_at_gmx.net)
Date: 03/28/05


Date: Mon, 28 Mar 2005 14:14:06 +0200

Hi,

I've set up a little application, in which I try to get some data with
sql-tags.
But altough the query retrieves the data from the database, I can't
display the value with c:out. I can't see any errors.
Here's the code:

<%@ taglib prefix="sql" uri="/WEB-INF/sql.tld" %>
<%@ taglib prefix="c" uri="/WEB-INF/c.tld" %>

<sql:query var="items" dataSource="jdbc/care">
SELECT * FROM data limit 1
</sql:query>

<!-- items are retrieved. I can see the results, when I debug it with
netbeans -->

<div class="content">
<c:forEach var="item" items="${items.rows}">
<h2>
<c:out value="${item.heading}"/>
</h2>
<div>
<div id="textbild"><img src="bilder/spacer.jpg" alt="" width="100"
height="137" /></div>
<p>
<c:out value="${item.state}"/>
</p>
</div>
</c:forEach>
.......
And the result in the html site is just:
....
${item.heading}....

${item.state}

I'm really stuck with this. Does anybody have a hint?

Regards, Andi