eolivelli commented on a change in pull request #69: URL: https://github.com/apache/openjpa/pull/69#discussion_r456500957
########## File path: openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/schema/Table.java ########## @@ -329,10 +341,19 @@ public Column getColumn(String name) { return getColumn(DBIdentifier.newIdentifier(name, DBIdentifierType.COLUMN, true)); } - public Column getColumn(DBIdentifier name) { + private Column internalGetColumn(DBIdentifier name) { if (DBIdentifier.isNull(name) || _colMap == null) return null; - return _colMap.get(DBIdentifier.toUpper(name)); + DBIdentifier key = normalizeColumnKey(name); + return _colMap.get(key); + } + + public Column getColumn(DBIdentifier name) { + return internalGetColumn(name); + } + + private DBIdentifier normalizeColumnKey(DBIdentifier name) { + return DBIdentifier.removeDelimiters(DBIdentifier.toUpper(name, true)); Review comment: > Makes sense to me to know if the identifier had been quoted or not and does not require a single signature change in methods I would like this change but it is not trivial, as I see that sometimes we are manipulating the internal `_name` of DBIdentifier, and tracking when it is already delimited or not seems to me an hard task. It can be done in a follow up patch. I will be happy to follow up in this direction I am trying now to reduce the overhead of removeDelimiters, it does unnecessary memory allocations ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org