File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
packages/server/src/complete/candidates Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -9,14 +9,14 @@ import { ICONS } from '../CompletionItemUtils'
99 * @param table
1010 * @returns
1111 */
12- function allTableNameCombinations ( table : Table ) : string [ ] {
13- if ( table . catalog ) {
14- return [ table . catalog + '.' + table . database + '.' + table . tableName ]
12+ function getFullyQualifiedTableName ( table : Table ) : string {
13+ if ( table . catalog && table . database ) {
14+ return table . catalog + '.' + table . database + '.' + table . tableName
1515 }
1616 if ( table . database ) {
17- return [ table . database + '.' + table . tableName ]
17+ return table . database + '.' + table . tableName
1818 }
19- return [ table . tableName ]
19+ return table . tableName
2020}
2121
2222export function createTableCandidates (
@@ -37,7 +37,7 @@ export function createTableCandidates(
3737 const qualificationLevelNeeded = qualificationNeeded - qualificationLevel
3838 switch ( qualificationLevelNeeded ) {
3939 case 0 :
40- return allTableNameCombinations ( table )
40+ return [ getFullyQualifiedTableName ( table ) ]
4141 case 1 :
4242 if ( table . catalog && table . database ) {
4343 return [ table . catalog + '.' + table . database ]
You can’t perform that action at this time.
0 commit comments