diff --git a/org.compiere.db.postgresql.provider/src/org/compiere/db/DB_PostgreSQL.java b/org.compiere.db.postgresql.provider/src/org/compiere/db/DB_PostgreSQL.java index 3035292f01..b8bec39070 100755 --- a/org.compiere.db.postgresql.provider/src/org/compiere/db/DB_PostgreSQL.java +++ b/org.compiere.db.postgresql.provider/src/org/compiere/db/DB_PostgreSQL.java @@ -1044,9 +1044,14 @@ public class DB_PostgreSQL implements AdempiereDatabase * @param end */ public String addPagingSQL(String sql, int start, int end) { - String newSql = sql + " " + NATIVE_MARKER + "LIMIT " + ( end - start + 1 ) - + " " + NATIVE_MARKER + "OFFSET " + (start - 1); - return newSql; + StringBuilder newSql = new StringBuilder(sql); + newSql.append(" ") + .append(markNativeKeyword("LIMIT ")) + .append(( end - start + 1 )) + .append(" ") + .append(markNativeKeyword("OFFSET ")) + .append((start - 1)); + return newSql.toString(); } public boolean isPagingSupported() {