optimize identifier management in SQL layer
@@ -83,8 +83,11 @@ public class OIdentifier extends SimpleNode {
if (value == null) {
return null;
}
+ if (value.contains("`")) {
return value.replaceAll("\\\\`", "`");
}
+ return value;
+ }
/**
* sets the value of the identifier. It can contain any values, this method can manage back-ticks (internally quote them), so
@@ -95,9 +98,12 @@ public class OIdentifier extends SimpleNode {
private void setStringValue(String s) {
if (s == null) {
value = null;
- } else {
+ } else if (s.contains("`")) {
value = s.replaceAll("`", "\\\\`");
+ } else {
+ value = s;
}
+
}
@Override
