db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Luca Ciocci <l.cio...@askweb.it>
Subject Error on order by (Criteria.addAscendingOrderByColumn)
Date Thu, 14 Sep 2006 15:29:15 GMT
I use Torque 3.2 in a large web project (I'm not new to Torque 3.x), and
I have some trouble ordering result with addAscendingOrderByColumn (or
addDescendingOrderByColumn) of Criteria object. I've got an exception
like this:

	at org.apache.torque.util.SQLBuilder.processOrderBy(SQLBuilder.java:506)
	at org.apache.torque.util.SQLBuilder.buildQueryClause(SQLBuilder.java:314)
	at org.apache.torque.util.BasePeer.createQuery(BasePeer.java:676)
	at org.apache.torque.util.BasePeer.doSelect(BasePeer.java:725)

This error happens ONLY when in order by method put a varchar column, if
I use (for example) a integer it works perfectly.

My project use Tomcat 5.5.9 + MySQL 4.1 and JDBC MySQL Connector3.0.16
(I've tried also the newer version, but the problem persists).

Can anyone help me?

Thanks, Luca.

To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org

View raw message