e203f1a48a
* feat(impala): add impala sqlLexer * feat(impala): add impala grammar * feat(impala): add alter table sql * feat(impala): update alter table sql * feat(impala): add alter db sql * feat(impala): add alter view sql * feat(impala): add compute stats/comment statement and update partition_desc for alter table * feat(impala): add drop statement sql * feat(impala): add revoke and grant sql * feat(impala): add create db/function/role/view sql * feat(impala): add describe/explain/invalidata_metadata/load_data sql * feat(impala): add refresh/set/shutdown sql * feat(impala): add truncate_table/use/values sql * fix(impala): update shutdown and invaliddate_metadata * feat(impala): add show/update/upsert sql * feat(impala): add create/insert sql * feat(impala): add select and delete sql * feat(impala): add impala tokens and fix todo * feat(impala): update impalaparser and some test unit * feat(impala): add syntax suggestion * feat(impala): add syntax suggestion * feat(impala): update test unit * feat(impala): remove reference * fix(impala): add statement for sqlname and collect tableName * fix(impala): fix syntax suggestion unit test * fix(impala): update syntax suggestion and collect column * feat(impala): add collect column create
45 lines
737 B
SQL
45 lines
737 B
SQL
SELECT * FROM cat.a;
|
|
|
|
SELECT name, calculate_age(birthdate) AS age FROM students;
|
|
|
|
ALTER DATABASE cat;
|
|
|
|
ALTER TABLE my_table CHANGE COLUMN age;
|
|
|
|
ALTER VIEW my_view;
|
|
|
|
DROP VIEW v;
|
|
|
|
DROP DATABASE my_db;
|
|
|
|
DROP TABLE my_table;
|
|
|
|
DROP FUNCTION my_func;
|
|
|
|
DELETE FROM my_table WHERE col1 LIKE 'prefix%';
|
|
|
|
CREATE VIEW cv;
|
|
|
|
CREATE TABLE cat.db ;
|
|
|
|
CREATE FUNCTION fnc;
|
|
|
|
CREATE DATABASE FIRST_DB;
|
|
|
|
SHOW TABLES in cat;
|
|
|
|
SHOW COLUMN STATS vie;
|
|
|
|
SHOW CREATE TABLE tb1;
|
|
|
|
SHOW CREATE VIEW v1;
|
|
|
|
SELECT id GROUP BY id;
|
|
|
|
SELECT id ORDER BY id;
|
|
|
|
CREATE TABLE census_data (last_name STRING);
|
|
|
|
ALTER TABLE my_table ADD COLUMN age INT COMMENT 'Updated Age';
|
|
|
|
CREATE TABLE kudu_no_partition_by_clause (id bigint PRIMARY KEY, s STRING, b BOOLEAN ) STORED AS KUDU; |