用途 | 语法 |
新建数据库 | CREATE DATABASE |
展示在该元数据中定义的所有数据库 | SHOW DATABASES |
查看数据库属性 | DESCRIBE DATABASE |
数据库属性变更 | ALTER DATABASE SET DBPROPERTIES |
删除数据库 | DROP DATABASE |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
用途 | 语法 |
新建数据表 | CREATE TABLE |
查询数据表建表信息 | SHOW CREATE TABLE |
查询表属性 | SHOW TBLPROPERTIES |
查询数据库中的所有表 | SHOW TABLES |
查看数据表列信息及元数据信息 | DESCRIBE TABLE |
向数据表添加列 | ALTER TABLE ADD COLUMNS |
对数据表新增列 | ALTER TABLE ADD COLUMN AFTER/FIRST |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
变更字段名称 | ALTER TABLE ... RENAME COLUMN |
删除数据表某个字段 | ALTER TABLE DROP COLUMN |
对数据表新增分区信息 | ALTER TABLE ADD PARTATION |
列出表分区 | SHOW PARTITIONS |
删除数据表分区信息 | ALTER TABLE DROP PARTITION |
对 Iceberg 表添加分区字段 | ALTER TABLE ADD PARTITION FIELD |
删除 Iceberg 表分区字段 | ALTER TABLE DROP PARTITION FIELD |
数据表属性变更 | ALTER TABLE SET TBLPROPERTIES |
数据表存储位置变更 | ALTER TABLE SET LOCATION |
修改表数据的排序方式 | ALTER TABLE ... WRITE ORDERED BY |
修改分区表的分配策略 | ALTER TABLE ... WRITE DISTRIBUTED BY PARTITION |
更新分区信息 | MSCK REPAIR TABLE |
删除元数据表 | DROP TABLE |
展示执行 sql 的逻辑或物理计划 | EXPLAIN |
调用表存储过程 | CALL STATEMENT |
用途 | 语法 |
将 select 结果创建为视图 | CREATE VIEW AS |
查询数据库中的视图 | SHOW VIEWS |
查看视图的列信息 | DESCRIBE VIEW |
展示视图创建语句 | SHOW CREATE VIEW |
查看视图列信息 | SHOW COLUMNS IN VIEW |
修改视图名称 | ALTER VIEW RENAME TO |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
修改视图属性 | ALTER VIEW SET TBLPROPERTIES |
删除视图 | DROP VIEW |
用途 | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
创建函数 | CREATE FUNCTION |
| |
| |
查看创建函数语法 | SHOW FUNCTION |
删除函数 | DROP FUNCTION |
用途 | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
插入一行数据 | INSERT STATEMENT |
| |
替换一行数据 | INSERT OVERWRITE |
行级数据更新操作,可用于替换 INSERT OVERWRITE 操作 | MERGE INTO |
Iceberg 表元数据查询 | TABLE METADATA |
将查询结果插入数据表 | INSERT INTO |
| |
删除 Iceberg 表的数据 | DELETE STATEMENT |
更新指定行 | UPDATE |
用途 | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
数据查询 | SELECT STATEMENT |
| |
| |
本页内容是否解决了您的问题?