|
@@ -178,6 +178,7 @@
|
|
|
beforeCursor: 'CREATE DATABASE foo COMMENT \'bla\' LOCATION \'/bla\' ',
|
|
beforeCursor: 'CREATE DATABASE foo COMMENT \'bla\' LOCATION \'/bla\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'hive',
|
|
dialect: 'hive',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['WITH DBPROPERTIES']
|
|
suggestKeywords: ['WITH DBPROPERTIES']
|
|
@@ -303,6 +304,7 @@
|
|
|
beforeCursor: 'CREATE FUNCTION boo(INT, BOOLEAN) RETURNS INT LOCATION \'/boo\' SYMBOL=\'baaa\'; ',
|
|
beforeCursor: 'CREATE FUNCTION boo(INT, BOOLEAN) RETURNS INT LOCATION \'/boo\' SYMBOL=\'baaa\'; ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
containsKeywords: ['SELECT'],
|
|
containsKeywords: ['SELECT'],
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false
|
|
lowerCase: false
|
|
@@ -316,6 +318,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' MERGE_FN=\'cos\' PREPARE_FN=\'cos\' CLOSE_FN=\'cos\' SERIALIZE_FN=\'cos\' FINALIZE_FN=\'cos\'; ',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' MERGE_FN=\'cos\' PREPARE_FN=\'cos\' CLOSE_FN=\'cos\' SERIALIZE_FN=\'cos\' FINALIZE_FN=\'cos\'; ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
containsKeywords: ['SELECT'],
|
|
containsKeywords: ['SELECT'],
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false
|
|
lowerCase: false
|
|
@@ -425,6 +428,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' ',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['INIT_FN', 'UPDATE_FN']
|
|
suggestKeywords: ['INIT_FN', 'UPDATE_FN']
|
|
@@ -437,6 +441,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestAnalyticFunctions: true,
|
|
suggestAnalyticFunctions: true,
|
|
@@ -451,6 +456,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' ',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['UPDATE_FN']
|
|
suggestKeywords: ['UPDATE_FN']
|
|
@@ -463,6 +469,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestAnalyticFunctions: true,
|
|
suggestAnalyticFunctions: true,
|
|
@@ -477,6 +484,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' ',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['MERGE_FN']
|
|
suggestKeywords: ['MERGE_FN']
|
|
@@ -490,6 +498,7 @@
|
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' MERGE_FN=\'tan\' PREPARE_FN=\'boo\' SERIALIZE_FN=\'baa\' ',
|
|
beforeCursor: 'CREATE AGGREGATE FUNCTION boo() RETURNS INT LOCATION \'/boo\' INIT_FN=\'cos\' UPDATE_FN=\'sin\' MERGE_FN=\'tan\' PREPARE_FN=\'boo\' SERIALIZE_FN=\'baa\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['FINALIZE_FN']
|
|
suggestKeywords: ['FINALIZE_FN']
|
|
@@ -648,6 +657,7 @@
|
|
|
beforeCursor: 'CREATE FUNCTION boo(INT, BOOLEAN) RETURNS INT LOCATION \'/boo\' ',
|
|
beforeCursor: 'CREATE FUNCTION boo(INT, BOOLEAN) RETURNS INT LOCATION \'/boo\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['SYMBOL']
|
|
suggestKeywords: ['SYMBOL']
|
|
@@ -1185,6 +1195,7 @@
|
|
|
beforeCursor: 'CREATE TABLE foo LIKE PARQUET \'/blabla/\' ',
|
|
beforeCursor: 'CREATE TABLE foo LIKE PARQUET \'/blabla/\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
containsKeywords: ['COMMENT', 'CACHED IN'],
|
|
containsKeywords: ['COMMENT', 'CACHED IN'],
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false
|
|
lowerCase: false
|
|
@@ -1197,6 +1208,7 @@
|
|
|
beforeCursor: 'CREATE TABLE foo (id int) LOCATION \'/baa\' ',
|
|
beforeCursor: 'CREATE TABLE foo (id int) LOCATION \'/baa\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['TBLPROPERTIES', 'CACHED IN', 'AS']
|
|
suggestKeywords: ['TBLPROPERTIES', 'CACHED IN', 'AS']
|
|
@@ -1411,6 +1423,7 @@
|
|
|
'CACHED ',
|
|
'CACHED ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['IN']
|
|
suggestKeywords: ['IN']
|
|
@@ -1428,6 +1441,7 @@
|
|
|
'CACHED ',
|
|
'CACHED ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['IN']
|
|
suggestKeywords: ['IN']
|
|
@@ -1474,6 +1488,7 @@
|
|
|
'CACHED IN \'boo\' AS ',
|
|
'CACHED IN \'boo\' AS ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'impala',
|
|
dialect: 'impala',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['SELECT']
|
|
suggestKeywords: ['SELECT']
|
|
@@ -1624,6 +1639,7 @@
|
|
|
beforeCursor: 'CREATE TABLE foo (id int) LOCATION \'/baa\' ',
|
|
beforeCursor: 'CREATE TABLE foo (id int) LOCATION \'/baa\' ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'hive',
|
|
dialect: 'hive',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['TBLPROPERTIES', 'AS']
|
|
suggestKeywords: ['TBLPROPERTIES', 'AS']
|
|
@@ -1920,6 +1936,7 @@
|
|
|
'STORED AS ORC LOCATION \'/asdf/boo/\' TBLPROPERTIES ("comment"="boo") AS ',
|
|
'STORED AS ORC LOCATION \'/asdf/boo/\' TBLPROPERTIES ("comment"="boo") AS ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'hive',
|
|
dialect: 'hive',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['SELECT']
|
|
suggestKeywords: ['SELECT']
|
|
@@ -1934,6 +1951,7 @@
|
|
|
'LOCATION \'/asdf/boo/\' TBLPROPERTIES ("comment"="boo") AS ',
|
|
'LOCATION \'/asdf/boo/\' TBLPROPERTIES ("comment"="boo") AS ',
|
|
|
afterCursor: '',
|
|
afterCursor: '',
|
|
|
dialect: 'hive',
|
|
dialect: 'hive',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestKeywords: ['SELECT']
|
|
suggestKeywords: ['SELECT']
|
|
@@ -1946,6 +1964,7 @@
|
|
|
beforeCursor: 'CREATE TEMPORARY EXTERNAL TABLE IF NOT EXISTS db.boo LIKE ',
|
|
beforeCursor: 'CREATE TEMPORARY EXTERNAL TABLE IF NOT EXISTS db.boo LIKE ',
|
|
|
afterCursor: ' LOCATION \'/some/loc\';',
|
|
afterCursor: ' LOCATION \'/some/loc\';',
|
|
|
dialect: 'hive',
|
|
dialect: 'hive',
|
|
|
|
|
+ hasLocations: true,
|
|
|
expectedResult: {
|
|
expectedResult: {
|
|
|
lowerCase: false,
|
|
lowerCase: false,
|
|
|
suggestTables: {},
|
|
suggestTables: {},
|