CLICKHOUSE建表语句

CREATE DATABASE IF NOT EXISTS test_database;

DROP table if exists product_id;
CREATE TABLE product_id
(
    factory_goods_id UInt32 COMMENT '工厂商品ID',
    goods_name String COMMENT '商品名称',
    shop_id UInt32 COMMENT '店铺ID',
    shop_name String COMMENT '店铺名称',
    create_time DateTime COMMENT '创建时间',
    update_time DateTime COMMENT '更新时间'
) ENGINE = MergeTree()
PRIMARY KEY factory_goods_id
ORDER BY factory_goods_id
posted @ 2023-07-18 18:29  甜菜波波  阅读(141)  评论(0编辑  收藏  举报