This commit is contained in:
wentch
2015-12-15 17:23:44 +08:00
parent f81577f46a
commit 9952b97d0e

View File

@@ -215,7 +215,7 @@ public final class EntityInfo<T> {
this.insertSQL = "INSERT INTO " + table + "(" + insertsb + ") VALUES(" + insertsb2 + ")";
StringBuilder updatesb = new StringBuilder();
for (String col : updatecols) {
if (updatesb.length() > 0) updatesb.append(',');
if (updatesb.length() > 0) updatesb.append(", ");
updatesb.append(col).append(" = ?");
}
this.updateSQL = "UPDATE " + table + " SET " + updatesb + " WHERE " + getPrimarySQLColumn(null) + " = ?";