Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 14 additions & 2 deletions mycli/sqlcompleter.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,23 @@ class SQLCompleter(Completer):
'SLAVE', 'SMALLINT', 'SMALLINT', 'START', 'STOP', 'TABLE',
'THEN', 'TINYINT', 'TO', 'TRANSACTION', 'TRIGGER', 'TRUNCATE',
'UNION', 'UNIQUE', 'UNSIGNED', 'UPDATE', 'USE', 'USER',
'USING', 'VALUES', 'VARCHAR', 'VIEW', 'WHEN', 'WHERE', 'WITH']
'USING', 'VALUES', 'VARCHAR', 'VIEW', 'WHEN', 'WHERE', 'WITH',
'JSON', 'ISNULL', 'GREATEST', 'LEAST', 'BLOB', 'BIT', 'OPAQUE',
'DATETIME', 'BOOLEAN', 'ARRAY', 'OBJECT', 'STRING', 'DOUBLE', 'NULL',
'ENUM', 'TEXT']
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we move ISNULL, GREATEST, and LEAST down to the function list?


functions = ['AVG', 'CONCAT', 'COUNT', 'DISTINCT', 'FIRST', 'FORMAT',
'FROM_UNIXTIME', 'LAST', 'LCASE', 'LEN', 'MAX', 'MID',
'MIN', 'NOW', 'ROUND', 'SUM', 'TOP', 'UCASE', 'UNIX_TIMESTAMP']
'MIN', 'NOW', 'ROUND', 'SUM', 'TOP', 'UCASE', 'UNIX_TIMESTAMP',
'JSON_APPEND', 'JSON_ARRAY', 'JSON_ARRAY_APPEND', 'JSON_ARRAY_INSERT',
'JSON_CONTAINS', 'JSON_CONTAINS_PATH', 'JSON_DEPTH', 'JSON_EXTRACT',
'JSON_INSERT', 'JSON_KEYS', 'JSON_LENGTH', 'JSON_MERGE',
'JSON_MERGE_PATCH', 'JSON_MERGE_PRESERVE', 'JSON_OBJECT', 'JSON_PRETTY',
'JSON_QUOTE', 'JSON_REMOVE', 'JSON_REPLACE', 'JSON_SEARCH', 'JSON_SET',
'JSON_STORAGE_SIZE', 'JSON_TYPE', 'JSON_UNQUOTE', 'JSON_VALID',
'JSON_ARRAYAVG', 'JSON_OBJECTAVG', 'JSON_OVERLAPS', 'JSON_SCHEMA_VALID',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you mean JSON_ARRAYAGG and JSON_OBJECTAGG?

'JSON_SCHEMA_VALIDATION_REPORT', 'JSON_STORAGE_FREE', 'JSON_TABLE',
'MEMBER_OF']
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MEMBER_OF() looks like it should be two words (MEMBER OF()).


show_items = []

Expand Down