import { NSDatabase } from '@sqltools/types' ; const reservedWordsArr = [ 'ABSOLUTE' , 'ACTION' , 'ADA' , 'ADD' , 'ALL' , 'ALLOCATE' , 'ALTER' , 'AND' , 'ANY' , 'ARE' , 'AS' , 'ASC' , 'ASSERTION' , 'AT' , 'AUTHORIZATION' , 'AVG' , 'BACKUP' , 'BEGIN' , 'BETWEEN' , 'BIT_LENGTH' , 'BIT' , 'BOTH' , 'BREAK' , 'BROWSE' , 'BULK' , 'BY' , 'CASCADE' , 'CASCADED' , 'CASE' , 'CAST' , 'CATALOG' , 'CHAR_LENGTH' , 'CHAR' , 'CHARACTER_LENGTH' , 'CHARACTER' , 'CHECK' , 'CHECKPOINT' , 'CLOSE' , 'CLUSTERED' , 'COALESCE' , 'COLLATE' , 'COLLATION' , 'COLUMN' , 'COMMIT' , 'COMPUTE' , 'CONNECT' , 'CONNECTION' , 'CONSTRAINT' , 'CONSTRAINTS' , 'CONTAINS' , 'CONTAINSTABLE' , 'CONTINUE' , 'CONVERT' , 'CORRESPONDING' , 'COUNT' , 'CREATE' , 'CROSS' , 'CURRENT_DATE' , 'CURRENT_TIME' , 'CURRENT_TIMESTAMP' , 'CURRENT_USER' , 'CURRENT' , 'CURSOR' , 'DATABASE' , 'DATE' , 'DAY' , 'DBCC' , 'DEALLOCATE' , 'DEC' , 'DECIMAL' , 'DECLARE' , 'DEFAULT' , 'DEFERRABLE' , 'DEFERRED' , 'DELETE' , 'DENY' , 'DESC' , 'DESCRIBE' , 'DESCRIPTOR' , 'DIAGNOSTICS' , 'DISCONNECT' , 'DISK' , 'DISTINCT' , 'DISTRIBUTED' , 'DOMAIN' , 'DOUBLE' , 'DROP' , 'DUMP' , 'ELSE' , 'END-EXEC' , 'END' , 'ERRLVL' , 'ESCAPE' , 'EXCEPT' , 'EXCEPTION' , 'EXEC' , 'EXECUTE' , 'EXISTS' , 'EXIT' , 'EXTERNAL' , 'EXTRACT' , 'FALSE' , 'FETCH' , 'FILE' , 'FILLFACTOR' , 'FIRST' , 'FLOAT' , 'FOR' , 'FOREIGN' , 'FORTRAN' , 'FOUND' , 'FREETEXT' , 'FREETEXTTABLE' , 'FROM' , 'FULL' , 'FUNCTION' , 'GET' , 'GLOBAL' , 'GO' , 'GOTO' , 'GRANT' , 'GROUP' , 'HAVING' , 'HOLDLOCK' , 'HOUR' , 'IDENTITY_INSERT' , 'IDENTITY' , 'IDENTITYCOL' , 'IF' , 'IMMEDIATE' , 'IN' , 'INCLUDE' , 'INDEX' , 'INDICATOR' , 'INITIALLY' , 'INNER' , 'INPUT' , 'INSENSITIVE' , 'INSERT' , 'INT' , 'INTEGER' , 'INTERSECT' , 'INTERVAL' , 'INTO' , 'IS' , 'ISOLATION' , 'JOIN' , 'KEY' , 'KILL' , 'LANGUAGE' , 'LAST' , 'LEADING' , 'LEFT' , 'LEVEL' , 'LIKE' , 'LINENO' , 'LOAD' , 'LOCAL' , 'LOWER' , 'MATCH' , 'MAX' , 'MERGE' , 'MIN' , 'MINUTE' , 'MODULE' , 'MONTH' , 'NAMES' , 'NATIONAL' , 'NATURAL' , 'NCHAR' , 'NEXT' , 'NO' , 'NOCHECK' , 'NONCLUSTERED' , 'NONE' , 'NOT' , 'NULL' , 'NULLIF' , 'NUMERIC' , 'OCTET_LENGTH' , 'OF' , 'OFF' , 'OFFSETS' , 'ON' , 'ONLY' , 'OPEN' , 'OPENDATASOURCE' , 'OPENQUERY' , 'OPENROWSET' , 'OPENXML' , 'OPTION' , 'OR' , 'ORDER' , 'OUTER' , 'OUTPUT' , 'OVER' , 'OVERLAPS' , 'PAD' , 'PARTIAL' , 'PASCAL' , 'PERCENT' , 'PIVOT' , 'PLAN' , 'POSITION' , 'PRECISION' , 'PREPARE' , 'PRESERVE' , 'PRIMARY' , 'PRINT' , 'PRIOR' , 'PRIVILEGES' , 'PROC' , 'PROCEDURE' , 'PUBLIC' , 'RAISERROR' , 'READ' , 'READTEXT' , 'REAL' , 'RECONFIGURE' , 'REFERENCES' , 'RELATIVE' , 'REPLICATION' , 'RESTORE' , 'RESTRICT' , 'RETURN' , 'REVERT' , 'REVOKE' , 'RIGHT' , 'ROLLBACK' , 'ROWCOUNT' , 'ROWGUIDCOL' , 'ROWS' , 'RULE' , 'SAVE' , 'SCHEMA' , 'SCROLL' , 'SECOND' , 'SECTION' , 'SECURITYAUDIT' , 'SELECT' , 'SEMANTICKEYPHRASETABLE' , 'SEMANTICSIMILARITYDETAILSTABLE' , 'SEMANTICSIMILARITYTABLE' , 'SESSION_USER' , 'SESSION' , 'SET' , 'SETUSER' , 'SHUTDOWN' , 'SIZE' , 'SMALLINT' , 'SOME' , 'SPACE' , 'SQL' , 'SQLCA' , 'SQLCODE' , 'SQLERROR' , 'SQLSTATE' , 'SQLWARNING' , 'STATISTICS' , 'SUBSTRING' , 'SUM' , 'SYSTEM_USER' , 'TABLE' , 'TABLESAMPLE' , 'TEMPORARY' , 'TEXTSIZE' , 'THEN' , 'TIME' , 'TIMESTAMP' , 'TIMEZONE_HOUR' , 'TIMEZONE_MINUTE' , 'TO' , 'TOP' , 'TRAILING' , 'TRAN' , 'TRANSACTION' , 'TRANSLATE' , 'TRANSLATION' , 'TRIGGER' , 'TRIM' , 'TRUE' , 'TRUNCATE' , 'TRY_CONVERT' , 'TSEQUAL' , 'UNION' , 'UNIQUE' , 'UNKNOWN' , 'UNPIVOT' , 'UPDATE' , 'UPDATETEXT' , 'UPPER' , 'USAGE' , 'USE' , 'USER' , 'USING' , 'VALUE' , 'VALUES' , 'VARCHAR' , 'VARYING' , 'VIEW' , 'WAITFOR' , 'WHEN' , 'WHENEVER' , 'WHERE' , 'WHILE' , 'WITH' , 'WITHIN GROUP' , 'WORK' , 'WRITE' , 'WRITETEXT' , 'YEAR' , 'ZONE' , ] ; const reservedWordsCompletion = reservedWordsArr . reduce ( ( agg , word ) => { agg [ word ] = { label : word , detail : word , filterText : word , sortText : ( [ 'SELECT' , 'CREATE' , 'UPDATE' , 'DELETE' ] . includes ( word ) ? '2:' : '' ) + word , documentation : { value : `\`\`\`yaml\nWORD: ${ word }\n\`\`\`` , kind : 'markdown' } } ; return agg ; } , { } ) ; export default reservedWordsCompletion ;