优化sql脚本执行顺序
This commit is contained in:
48
doc/sql/createtable/regions_info_postgres.sql
Normal file
48
doc/sql/createtable/regions_info_postgres.sql
Normal file
@@ -0,0 +1,48 @@
|
||||
CREATE TABLE regions_info
|
||||
(
|
||||
id SERIAL PRIMARY KEY,
|
||||
name VARCHAR(50) NULL,
|
||||
level INTEGER NULL,
|
||||
pid INTEGER DEFAULT 0 NULL,
|
||||
lon DECIMAL(10, 6) NULL,
|
||||
lat DECIMAL(10, 6) NULL,
|
||||
region_code VARCHAR(128) NULL,
|
||||
full_name VARCHAR(200) NULL,
|
||||
vendor_region_id BIGINT NULL,
|
||||
store_city_id BIGINT NULL,
|
||||
hotel_city_code VARCHAR(128) NULL,
|
||||
hotel_city_pinyin VARCHAR(128) NULL,
|
||||
hotel_city_initials VARCHAR(4) NULL,
|
||||
sight_city_name VARCHAR(32) NULL,
|
||||
is_deleted INTEGER DEFAULT 0 NULL,
|
||||
create_time TIMESTAMP(6) NULL,
|
||||
create_user int8 NULL,
|
||||
update_time TIMESTAMP(6) NULL,
|
||||
update_user int8 NULL,
|
||||
status INTEGER NULL,
|
||||
create_dept BIGINT NULL
|
||||
);
|
||||
|
||||
COMMENT ON TABLE regions_info IS '地区详情表';
|
||||
COMMENT ON COLUMN regions_info.id IS '主键';
|
||||
COMMENT ON COLUMN regions_info.name IS '名称';
|
||||
COMMENT ON COLUMN regions_info.level IS '层级';
|
||||
COMMENT ON COLUMN regions_info.pid IS '父主键';
|
||||
COMMENT ON COLUMN regions_info.lon IS '经度';
|
||||
COMMENT ON COLUMN regions_info.lat IS '纬度';
|
||||
COMMENT ON COLUMN regions_info.region_code IS '地区编码';
|
||||
COMMENT ON COLUMN regions_info.full_name IS '全称';
|
||||
COMMENT ON COLUMN regions_info.vendor_region_id IS '服务商地区表id';
|
||||
COMMENT ON COLUMN regions_info.store_city_id IS '城市店铺id';
|
||||
COMMENT ON COLUMN regions_info.hotel_city_code IS '酒店地区编码';
|
||||
COMMENT ON COLUMN regions_info.hotel_city_pinyin IS '酒店地区拼音';
|
||||
COMMENT ON COLUMN regions_info.hotel_city_initials IS '酒店地区拼音首字母';
|
||||
COMMENT ON COLUMN regions_info.sight_city_name IS '景点城市名';
|
||||
COMMENT ON COLUMN regions_info.is_deleted IS '是否删除';
|
||||
COMMENT ON COLUMN regions_info.create_user IS '创建人';
|
||||
COMMENT ON COLUMN regions_info.create_dept IS '创建部门';
|
||||
COMMENT ON COLUMN regions_info.create_time IS '创建时间';
|
||||
COMMENT ON COLUMN regions_info.update_user IS '修改人';
|
||||
COMMENT ON COLUMN regions_info.update_time IS '修改时间';
|
||||
COMMENT ON COLUMN regions_info.status IS '状态';
|
||||
|
||||
Reference in New Issue
Block a user