更新时间:2024-12-10 GMT+08:00
分享

CLUSTERED KEY

在ADB中,CLUSTERED KEY:聚集索引,定义表中的排序列,聚集索引中键值的逻辑顺序决定了表中相应行的物理顺序。GaussDB(DWS)不支持该属性修改表定义信息,DSC迁移时会将该关键字删除。

输入示例

1
2
3
4
5
6
DROP TABLE IF EXISTS unsupport_parse_test;
CREATE TABLE `unsupport_parse_test` (
    `username` int,
     clustered key clustered_key(shopid ASC, datetype ASC)
);
DROP TABLE IF EXISTS unsupport_parse_test;

输出示例

1
2
3
4
5
DROP TABLE IF EXISTS "public"."unsupport_parse_test";
CREATE TABLE "public"."unsupport_parse_test" (
  "username" INTEGER
) WITH (ORIENTATION = ROW, COMPRESSION = NO) NOCOMPRESS DISTRIBUTE BY HASH ("username");
DROP TABLE IF EXISTS "public"."unsupport_parse_test";

相关文档