buffer.append(limit.getCommentOffset() != null ? " " + limit.getCommentOffset() + ExpressionDeParser.LINE_SEPARATOR : "").append(" Offset") .append(limit.getCommentOffsetValue() != null ? " " + limit.getCommentOffsetValue() + ExpressionDeParser.LINE_SEPARATOR : "").append(" ?"); } else if (limit.getOffset() != 0) { buffer.append(limit.getCommentOffset() != null ? " " + limit.getCommentOffset() + ExpressionDeParser.LINE_SEPARATOR : "").append(" Offset ") .append(limit.getCommentOffsetValue() != null ? " " + limit.getCommentOffsetValue() + " " + ExpressionDeParser.LINE_SEPARATOR : "").append(limit.getOffset());
public String toString() { String retVal = ""; if (rowCount > 0 || rowCountJdbcParameter || limitAll) { if (limitAll) { retVal += (getCommentLimit() != null ? " "+getCommentLimit() : "") + " LIMIT " + (getCommentAll() != null ? getCommentAll()+" " : "") + "ALL"; } else { if (isComma()) { retVal +=(getCommentLimit() != null ? " "+getCommentLimit() : "") + " LIMIT " + (getCommentLimitValue() != null ? getCommentLimitValue()+" " : "") + (offsetJdbcParameter ? "?" : offset + ""); retVal +=(getCommentComma() != null ? " "+getCommentComma()+" " : "") + ", " + (getCommentAfterCommaValue() != null ? getCommentAfterCommaValue()+" " : "") + (rowCountJdbcParameter ? "?" : rowCount + ""); return retVal; } else { retVal += (getCommentLimit() != null ? " "+getCommentLimit() : "") + " LIMIT " + (getCommentLimitValue() != null ? getCommentLimitValue()+" " : "") + (rowCountJdbcParameter ? "?" : rowCount + ""); } } } if (offset > 0 || offsetJdbcParameter) { retVal += (getCommentOffset() != null ? " "+getCommentOffset() : "") + " OFFSET " + (getCommentOffsetValue() != null ? getCommentOffsetValue()+" " : "") + (offsetJdbcParameter ? "?" : offset + ""); } return retVal; }