@abaplint/core 2.98.0 → 2.98.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/src/registry.js
CHANGED
|
@@ -62,9 +62,18 @@ class SelectSingleFullKey {
|
|
|
62
62
|
continue;
|
|
63
63
|
}
|
|
64
64
|
const tabl = this.findReference(databaseTable.getFirstToken().getStart(), syntax.spaghetti, file);
|
|
65
|
-
const
|
|
65
|
+
const table = this.reg.getObject("TABL", tabl);
|
|
66
|
+
const keys = table.listKeys(this.reg);
|
|
67
|
+
// const type = table.parseType(this.reg);
|
|
66
68
|
const cond = s.findFirstExpression(__1.Expressions.SQLCond);
|
|
67
|
-
const set = new Set(
|
|
69
|
+
const set = new Set();
|
|
70
|
+
for (const key of keys) {
|
|
71
|
+
if (key === "MANDT") {
|
|
72
|
+
// todo, it should check for the correct type instead
|
|
73
|
+
continue;
|
|
74
|
+
}
|
|
75
|
+
set.add(key);
|
|
76
|
+
}
|
|
68
77
|
for (const compare of (cond === null || cond === void 0 ? void 0 : cond.findAllExpressionsRecursive(__1.Expressions.SQLCompare)) || []) {
|
|
69
78
|
if (compare.getChildren().length === 3) {
|
|
70
79
|
const fname = (_a = compare.findDirectExpression(__1.Expressions.SQLFieldName)) === null || _a === void 0 ? void 0 : _a.concatTokens().toUpperCase();
|