clickhouse-cli icon indicating copy to clipboard operation
clickhouse-cli copied to clipboard

Autocompletion bugs & improvements

Open hatarist opened this issue 8 years ago • 1 comments

(in no particular order)

  • datatype completion is broken for the second column (and later) 1

  • only one completion is displayed in case of SELECT * FROM sys<tab> 2

  • table autocompletion should have the current database in mind 3

  • aliased column in subqueries don't work src 2017-05-09 at 07 16 51

  • autocompletion prepends the table name if called inside the function's parentheses scr 2017-05-26 at 13 46 12

hatarist avatar May 09 '17 04:05 hatarist

Autocompletion should get the list of supported functions/datatypes/whatnot from the server

The lists are currently hard-coded in the clickhouse_cli/clickhouse/definitions.py:

  • FUNCTIONS, CASE_INSENSITIVE_FUNCTIONS, AGGREGATION_FUNCTIONS -> SELECT * FROM system.functions; (should also take care of is_aggregate and case_insensitive) for is_aggregate ones, should add suffixes from SELECT * FROM system.aggregate_function_combinators;

  • DATATYPES -> SELECT * FROM system.data_type_families;

hatarist avatar Nov 25 '18 17:11 hatarist