* query statement.
* @return The ordering statement
*/
protected StatementText generateOrderingStatement()
{
StatementText orderByStmt = null;
if (orderingExpressions != null && orderingExpressions.length > 0)
{
orderByStmt = new StatementText();
for (int i=0; i<orderingExpressions.length; ++i)
{
if (i > 0)
{
orderByStmt.append(',');
}
orderByStmt.append(Integer.toString(orderingColumnIndexes[i]));
if (orderingDirections[i])
{
orderByStmt.append(" DESC");
}
}
}
return orderByStmt;