提交 93de0fef 编写于 作者: S Serge Rider

#5983 SQL Server: use synonyms in schema child objects search


Former-commit-id: 6d76b254
上级 cc9464ac
......@@ -230,8 +230,11 @@ public class SQLServerSchema implements DBSSchema, DBPSaveableObject, DBPQualifi
}
@Override
public Collection<? extends SQLServerTableBase> getChildren(@NotNull DBRProgressMonitor monitor) throws DBException {
return tableCache.getAllObjects(monitor, this);
public List<SQLServerObject> getChildren(@NotNull DBRProgressMonitor monitor) throws DBException {
List<SQLServerObject> result = new ArrayList<>();
result.addAll(tableCache.getAllObjects(monitor, this));
result.addAll(synonymCache.getAllObjects(monitor, this));
return result;
}
@Override
......@@ -248,6 +251,7 @@ public class SQLServerSchema implements DBSSchema, DBPSaveableObject, DBPQualifi
public void cacheStructure(@NotNull DBRProgressMonitor monitor, int scope) throws DBException {
if ((scope & STRUCT_ENTITIES) == STRUCT_ENTITIES) {
tableCache.getAllObjects(monitor, this);
synonymCache.getAllObjects(monitor, this);
}
if ((scope & STRUCT_ATTRIBUTES) == STRUCT_ATTRIBUTES) {
tableCache.getChildren(monitor, this, null);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册