Fix column name escaping again

This commit is contained in:
Marc Baloup 2019-07-21 13:41:17 +02:00
parent d0a80abd41
commit b3b0349ebd
2 changed files with 2 additions and 2 deletions

View File

@ -283,7 +283,7 @@ public abstract class SQLElement<E extends SQLElement<E>> {
}
first = false;
concat_vals += " ? ";
concat_fields += entry.getKey().getName();
concat_fields += "`" + entry.getKey().getName() + "`";
addValueToSQLObjectList(psValues, entry.getKey(), entry.getValue());
}

View File

@ -86,7 +86,7 @@ public class SQLElementList<E extends SQLElement<E>> extends ArrayList<E> {
List<Object> psValues = new ArrayList<>();
for (Map.Entry<SQLField<E, ?>, Object> entry : modifiedValues.entrySet()) {
sqlSet += entry.getKey().getName() + " = ? ,";
sqlSet += "`" + entry.getKey().getName() + "` = ? ,";
SQLElement.addValueToSQLObjectList(psValues, entry.getKey(), entry.getValue());
}