You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by Bing Zou <xi...@gmail.com> on 2005/07/20 21:41:33 UTC

Automatic dynamic sorting.

Hi,

I have one question about dynamic sorting:
Now for every sql statement that I want to apply dynamic sorting, I
have to manually add "$OrderByClause$" at the end of that sql
statement, which will be replaced by real "ORDER BY xxx" at runtime.
I am wondering whether there is a way to append $OrderByClause$ to
every sql statement that iBATIS loads automatically, so that the
original sql statements look a little bit simpler. And I could save
some time in checking and adding this small piece of code to every
existing query.

Thanks.
Bing