Skip to content

Commit 2fd1877

Browse files
author
Kusto Build System
committed
Auto-sync from Azure-Kusto-Service
1 parent cd6b444 commit 2fd1877

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

src/Kusto.Language/Binder/Binder_Names.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,14 @@ private bool GetMatchingSymbolsInNormalScope(string name, SymbolMatch match, Syn
588588
// other items in database (tables, etc)
589589
if (list.Count == 0 && _currentDatabase != null)
590590
{
591-
_currentDatabase.GetMembers(name, match, list);
591+
// try matching without external tables first
592+
_currentDatabase.GetMembers(name, match & ~SymbolMatch.ExternalTable, list);
593+
594+
// if nothing was found, try matching external tables (if requested)
595+
if (list.Count == 0 && (match & SymbolMatch.ExternalTable) != 0)
596+
{
597+
_currentDatabase.GetMembers(name, SymbolMatch.ExternalTable, list);
598+
}
592599
}
593600

594601
// databases can be directly referenced in commands

src/Kusto.Language/Symbols/SymbolMatch.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ public enum SymbolMatch
114114
/// <summary>
115115
/// Any column, table, function or local, scalar or tabular
116116
/// </summary>
117-
Default = Column | Table | Function | View | Local | MaterializedView | EntityGroup | EntityGroupElement | Graph,
117+
Default = Column | Table | Function | View | Local | MaterializedView | EntityGroup | EntityGroupElement | Graph | ExternalTable,
118118
}
119119

120120
public static class SymbolMatchExtensions

0 commit comments

Comments
 (0)