Przeglądaj źródła

HUE-4789 [editor] Add autocompletion of values when the cursor is inside quoted values

Johan Ahlen 9 lat temu
rodzic
commit
37458d3

+ 8 - 5
desktop/core/src/desktop/static/desktop/js/autocomplete/jison/sql.jisonlex

@@ -444,8 +444,7 @@
 
 \`                                         { this.begin('backtickedValue'); return 'BACKTICK'; }
 <backtickedValue>[^`]+                     {
-                                             if (yytext.indexOf('\u2020') !== -1 || yytext.indexOf('\u2021') !== -1) {
-                                               this.popState();
+                                             if (parser.handleQuotedValueWithCursor(this, yytext, yylloc, '`')) {
                                                return 'PARTIAL_VALUE';
                                              }
                                              return 'VALUE';
@@ -454,8 +453,7 @@
 
 \'                                         { this.begin('singleQuotedValue'); return 'SINGLE_QUOTE'; }
 <singleQuotedValue>(?:\\[']|[^'])+         {
-                                             if (yytext.indexOf('\u2020') !== -1 || yytext.indexOf('\u2021') !== -1) {
-                                               this.popState();
+                                             if (parser.handleQuotedValueWithCursor(this, yytext, yylloc, '\'')) {
                                                return 'PARTIAL_VALUE';
                                              }
                                              return 'VALUE';
@@ -463,7 +461,12 @@
 <singleQuotedValue>\'                      { this.popState(); return 'SINGLE_QUOTE'; }
 
 \"                                         { this.begin('doubleQuotedValue'); return 'DOUBLE_QUOTE'; }
-<doubleQuotedValue>(?:\\["]|[^"])+         { return 'VALUE'; }
+<doubleQuotedValue>(?:\\["]|[^"])+         {
+                                             if (parser.handleQuotedValueWithCursor(this, yytext, yylloc, '"')) {
+                                               return 'PARTIAL_VALUE';
+                                             }
+                                             return 'VALUE';
+                                           }
 <doubleQuotedValue>\"                      { this.popState(); return 'DOUBLE_QUOTE'; }
 
 <<EOF>>                                    { return 'EOF'; }

+ 28 - 2
desktop/core/src/desktop/static/desktop/js/autocomplete/jison/sql_main.jison

@@ -463,12 +463,15 @@ SingleQuotedValue_EDIT
  : 'SINGLE_QUOTE' 'PARTIAL_VALUE'
  ;
 
-
 DoubleQuotedValue
  : 'DOUBLE_QUOTE' 'VALUE' 'DOUBLE_QUOTE'  -> $2
  | 'DOUBLE_QUOTE' 'DOUBLE_QUOTE'          -> ''
  ;
 
+DoubleQuotedValue_EDIT
+ : 'DOUBLE_QUOTE' 'PARTIAL_VALUE'
+ ;
+
 QuotedValue
  : SingleQuotedValue
  | DoubleQuotedValue
@@ -2064,7 +2067,8 @@ NonParenthesizedValueExpressionPrimary
  ;
 
 NonParenthesizedValueExpressionPrimary_EDIT
- : ColumnReference_EDIT
+ : UnsignedValueSpecification_EDIT
+ | ColumnReference_EDIT
    {
      if ($1.suggestKeywords) {
        $$ = { types: ['COLREF'], columnReference: $1, suggestKeywords: $1.suggestKeywords };
@@ -2097,11 +2101,22 @@ UnsignedValueSpecification
  : UnsignedLiteral
  ;
 
+UnsignedValueSpecification_EDIT
+ : UnsignedLiteral_EDIT
+   {
+     suggestValues($1);
+   }
+ ;
+
 UnsignedLiteral
  : UnsignedNumericLiteral  -> { types: [ 'NUMBER' ] }
  | GeneralLiteral
  ;
 
+UnsignedLiteral_EDIT
+ : GeneralLiteral_EDIT
+ ;
+
 UnsignedNumericLiteral
  : ExactNumericLiteral
  | ApproximateNumericLiteral
@@ -2126,6 +2141,17 @@ GeneralLiteral
  | TruthValue         -> { types: [ 'BOOLEAN' ] }
  ;
 
+GeneralLiteral_EDIT
+ : SingleQuotedValue_EDIT
+  {
+    $$ = { partialQuote: '\'', missingEndQuote: parser.yy.missingEndQuote };
+  }
+ | DoubleQuotedValue_EDIT
+  {
+    $$ = { partialQuote: '"', missingEndQuote: parser.yy.missingEndQuote };
+  }
+ ;
+
 TruthValue
  : 'TRUE'
  | 'FALSE'

Plik diff jest za duży
+ 0 - 0
desktop/core/src/desktop/static/desktop/js/autocomplete/sql.js


+ 26 - 1
desktop/core/src/desktop/static/desktop/js/autocomplete/sql_support.js

@@ -998,7 +998,7 @@ var suggestHdfs = function (details) {
 };
 
 var suggestValues = function (details) {
-  parser.yy.result.suggestValues = true;
+  parser.yy.result.suggestValues = details || {};
 };
 
 var determineCase = function (text) {
@@ -1008,6 +1008,31 @@ var determineCase = function (text) {
   }
 };
 
+parser.handleQuotedValueWithCursor = function(lexer, yytext, yylloc, quoteChar) {
+  if (yytext.indexOf('\u2020') !== -1 || yytext.indexOf('\u2021') !== -1) {
+    parser.yy.partialCursor = yytext.indexOf('\u2021') !== -1;
+    var cursorIndex = parser.yy.partialCursor ? yytext.indexOf('\u2021') : yytext.indexOf('\u2020');
+    parser.yy.cursorFound = {
+      first_line: yylloc.first_line,
+      last_line: yylloc.last_line,
+      first_column: yylloc.first_column + cursorIndex,
+      last_column: yylloc.first_column + cursorIndex + 1
+    };
+    var remainder = yytext.substring(cursorIndex + 1);
+    var remainingQuotes = (lexer.upcomingInput().match(new RegExp(quoteChar, 'g')) || []).length;
+    if (remainingQuotes > 0 && remainingQuotes & 1  != 0) {
+      parser.yy.missingEndQuote = false;
+      lexer.input();
+    } else {
+      parser.yy.missingEndQuote = true;
+      lexer.unput(remainder);
+    }
+    lexer.popState();
+    return true;
+  }
+  return false;
+};
+
 var lexerModified = false;
 
 /**

+ 6 - 3
desktop/core/src/desktop/static/desktop/js/sqlAutocompleter2.js

@@ -155,7 +155,7 @@
       var suggestValuesDeferral = $.Deferred();
       colRefDeferral.done(function () {
         if (colRef !== null) {
-          self.addValues(colRef, completions);
+          self.addValues(parseResult, colRef, completions);
         }
         suggestValuesDeferral.resolve();
       });
@@ -282,11 +282,14 @@
     }
   };
 
-  SqlAutocompleter2.prototype.addValues = function (columnReference, completions) {
+  SqlAutocompleter2.prototype.addValues = function (parseResult, columnReference, completions) {
     if (columnReference.sample) {
+      var suggestValues = parseResult.suggestValues;
       var isString = columnReference.type === "string";
+      var startQuote = suggestValues.partialQuote ? '' : '\'';
+      var endQuote = typeof suggestValues.missingEndQuote !== 'undefined' && suggestValues.missingEndQuote === false ? '' : suggestValues.partialQuote || '\'';
       columnReference.sample.forEach(function (sample) {
-        completions.push({meta: 'value', value: isString ? "'" + sample + "'" : new String(sample), weight: DEFAULT_WEIGHTS.SAMPLE })
+        completions.push({meta: 'value', value: isString ? startQuote + sample + endQuote : new String(sample), weight: DEFAULT_WEIGHTS.SAMPLE })
       });
     }
   };

+ 1 - 1
desktop/core/src/desktop/static/desktop/spec/autocomplete/sqlSpecDrop.js

@@ -215,7 +215,7 @@ define([
           containsKeywords: ['EXISTS'],
           expectedResult: {
             lowerCase: false,
-            suggestValues: true,
+            suggestValues: {},
             suggestFunctions: { types: ['COLREF'] },
             colRef: { identifierChain: [{ name: 'boo'}, { name: 'baa' }, { name: 'id' }] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'boo' }, { name: 'baa' }] }] }

+ 125 - 60
desktop/core/src/desktop/static/desktop/spec/autocomplete/sqlSpecSelect.js

@@ -602,41 +602,6 @@ define([
         });
       });
 
-      it('should handle 100k rows before "SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);|"', function() {
-        var beforeCursor = '';
-        for (var i = 0; i < 100000; i++) {
-          beforeCursor += 'SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);\n';
-        }
-        assertAutoComplete({
-          beforeCursor: beforeCursor,
-          afterCursor: ';SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);',
-          dialect: 'hive',
-          hasLocations: true,
-          noErrors: true,
-          containsKeywords: ['SELECT'],
-          expectedResult: {
-            lowerCase: false
-          }
-        });
-      });
-
-      it('should handle 100k rows after "SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);|"', function() {
-        var afterCursor = ';\n';
-        for (var i = 0; i < 100000; i++) {
-          afterCursor += 'SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);\n';
-        }
-        assertAutoComplete({
-          beforeCursor: '',
-          afterCursor: afterCursor,
-          dialect: 'hive',
-          noErrors: true,
-          containsKeywords: ['SELECT'],
-          expectedResult: {
-            lowerCase: false
-          }
-        });
-      });
-
       it('should handle 100k rows before and after "SELECT * FROM foo WHERE (bar = \'bla\') AND (ble = 1);|"', function() {
         var beforeCursor = '';
         var afterCursor = ';\n';
@@ -1826,11 +1791,111 @@ define([
           afterCursor: ',bla) FROM bar;',
           hasLocations: true,
           containsKeywords: ['CASE'],
+          hasErrors: false,
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'bar' }] }] },
-            suggestValues: true,
+            suggestValues: {},
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = \'| FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = \'',
+          afterCursor: ' FROM bar;',
+          hasErrors: false,
+          expectedResult: {
+            locations: [
+              { type: 'column', location: { first_line: 1, last_line: 1, first_column: 8, last_column: 10 }, identifierChain: [{ name: 'bar' }, { name: 'bl' }] },
+              { type: 'table', location: { first_line: 1, last_line: 1, first_column: 20, last_column: 23 }, identifierChain: [{ name: 'bar' }] }
+            ],
+            lowerCase: false,
+            suggestValues: { partialQuote: '\'', missingEndQuote: true },
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = \'|\' FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = \'',
+          afterCursor: '\' FROM bar;',
+          hasErrors: false,
+          expectedResult: {
+            locations: [
+              { type: 'column', location: { first_line: 1, last_line: 1, first_column: 8, last_column: 10 }, identifierChain: [{ name: 'bar' }, { name: 'bl' }] },
+              { type: 'table', location: { first_line: 1, last_line: 1, first_column: 21, last_column: 24 }, identifierChain: [{ name: 'bar' }] }
+            ],
+            lowerCase: false,
+            suggestValues: { partialQuote: '\'', missingEndQuote: false },
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = \'bl| bl\' FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = \'bl',
+          afterCursor: ' bl\' FROM bar;',
+          hasErrors: false,
+          expectedResult: {
+            locations: [
+              { type: 'column', location: { first_line: 1, last_line: 1, first_column: 8, last_column: 10 }, identifierChain: [{ name: 'bar' }, { name: 'bl' }] },
+              { type: 'table', location: { first_line: 1, last_line: 1, first_column: 26, last_column: 29 }, identifierChain: [{ name: 'bar' }] }
+            ],
+            lowerCase: false,
+            suggestValues: { partialQuote: '\'', missingEndQuote: false },
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = "| FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = "',
+          afterCursor: ' FROM bar;',
+          hasLocations: true,
+          hasErrors: false,
+          expectedResult: {
+            lowerCase: false,
+            suggestValues: { partialQuote: '"', missingEndQuote: true },
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = "|" FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = "',
+          afterCursor: '" FROM bar;',
+          hasErrors: false,
+          expectedResult: {
+            locations: [
+              { type: 'column', location: { first_line: 1, last_line: 1, first_column: 8, last_column: 10 }, identifierChain: [{ name: 'bar' }, { name: 'bl' }] },
+              { type: 'table', location: { first_line: 1, last_line: 1, first_column: 21, last_column: 24 }, identifierChain: [{ name: 'bar' }] }
+            ],
+            lowerCase: false,
+            suggestValues: { partialQuote: '"', missingEndQuote: false },
+            colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
+          }
+        });
+      });
+
+      it('should suggest columns and values for "SELECT bl = "bl| bl" FROM bar;"', function() {
+        assertAutoComplete({
+          beforeCursor: 'SELECT bl = "bl',
+          afterCursor: ' bl" FROM bar;',
+          hasErrors: false,
+          expectedResult: {
+            locations: [
+              { type: 'column', location: { first_line: 1, last_line: 1, first_column: 8, last_column: 10 }, identifierChain: [{ name: 'bar' }, { name: 'bl' }] },
+              { type: 'table', location: { first_line: 1, last_line: 1, first_column: 26, last_column: 29 }, identifierChain: [{ name: 'bar' }] }
+            ],
+            lowerCase: false,
+            suggestValues: { partialQuote: '"', missingEndQuote: false },
             colRef: { identifierChain: [{ name: 'bar' }, { name: 'bl' }] }
           }
         });
@@ -2315,7 +2380,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'a' }] }
           }
         });
@@ -2331,7 +2396,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'a' }] }
           }
         });
@@ -2361,7 +2426,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
         });
@@ -2635,7 +2700,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain :[{ name: 'testTable' }, { name :'a'}] }
           }
         });
@@ -2707,7 +2772,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'a' }] }
           }
         });
@@ -3555,7 +3620,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }], alias: 't' }] },
             suggestIdentifiers : [{ name: 't.', type: 'alias' }, { name: 'tm.', type: 'alias' }],
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'testMap' }, { name: 'key' }] }
@@ -3577,7 +3642,7 @@ define([
             ],
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }], alias: 't' }] },
             suggestIdentifiers : [{ name: 't.', type: 'alias' }, { name: 'm.', type: 'alias' }],
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'testMap' }, { name: 'field' }] }
@@ -3856,7 +3921,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'id' }] }
           }
@@ -3926,7 +3991,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['NUMBER'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['NUMBER'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'id' }] }
           }
@@ -4345,7 +4410,7 @@ define([
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'id' }] }
           }
         });
@@ -4360,7 +4425,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'id' }] }
           }
@@ -4376,7 +4441,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4392,7 +4457,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4408,7 +4473,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4424,7 +4489,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4440,7 +4505,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4456,7 +4521,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4472,7 +4537,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -4488,7 +4553,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'd' }] }
           }
@@ -5112,7 +5177,7 @@ define([
           expectedResult: {
             lowerCase: false,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable' }] }] },
             colRef: { identifierChain: [{ name: 'testTable' }, { name: 'a' }] }
           }
@@ -6443,7 +6508,7 @@ define([
           hasLocations: true,
           containsKeywords: ['CASE'],
           expectedResult: {
-            suggestValues: true,
+            suggestValues: {},
             colRef: { identifierChain: [{ name: 'testTable1' }, { name: 'testColumn1'}] },
             suggestFunctions: { types: ['COLREF'] },
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'testTable1' }] }, { identifierChain: [{ name: 'testTable2' }] }] },
@@ -6980,7 +7045,7 @@ define([
             lowerCase: false,
             suggestKeywords: ['SELECT'],
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'foo' }] }] },
             colRef: { identifierChain: [{ name: 'foo' }, { name: 'bar'}] }
           }
@@ -6996,7 +7061,7 @@ define([
             lowerCase: true,
             suggestKeywords: ['SELECT'],
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'foo' }] }, { identifierChain: [{ name: 'bar' }] }] },
             suggestIdentifiers: [{ name: 'foo.', type: 'table' }, { name: 'bar.', type: 'table' }],
             colRef: { identifierChain: [{ name: 'bar' }, {name: 'bla'}] }
@@ -7013,7 +7078,7 @@ define([
           expectedResult: {
             lowerCase: true,
             suggestFunctions: { types: ['COLREF'] },
-            suggestValues: true,
+            suggestValues: {},
             suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'foo' }] }, { identifierChain: [{ name: 'bar' }] }] },
             suggestIdentifiers: [{ name: 'foo.', type: 'table' }, { name: 'bar.', type: 'table' }],
             colRef: { identifierChain: [{ name: 'bar' }, {name: 'bla'}] }

+ 1 - 1
desktop/core/src/desktop/static/desktop/spec/autocomplete/sqlSpecUpdate.js

@@ -195,7 +195,7 @@ define([
             {type: 'column', location: { first_line: 1, last_line: 1, first_column: 38, last_column: 40 }, identifierChain: [{ name: 'bar'}, { name: 'foo' }, { name: 'id'}]}
           ],
           suggestFunctions: { types: ['COLREF'] },
-          suggestValues: true,
+          suggestValues: {},
           colRef: { identifierChain: [{ name: 'bar' }, { name: 'foo' }, { name: 'id' }] },
           suggestColumns: { types: ['COLREF'], tables: [{ identifierChain: [{ name: 'bar'}, { name: 'foo' }] }] },
           lowerCase: false

Niektóre pliki nie zostały wyświetlone z powodu dużej ilości zmienionych plików