23 lines
866 B
SQL
23 lines
866 B
SQL
create table hrsa_sub_table_item
|
|
(
|
|
id bigint primary key comment 'ID' ,
|
|
create_time datetime comment '创建时间' ,
|
|
update_time datetime comment '修改时间' ,
|
|
creator bigint comment '创建人id' ,
|
|
delete_type int default 0 comment '是否删除' ,
|
|
tenant_key varchar(10) comment '租户KEY' ,
|
|
table_id bigint not null comment '数据表id' ,
|
|
item_name varchar(50) not null comment '统计项名称' ,
|
|
item_value varchar(500) not null comment '统计项集合' ,
|
|
index_value int not null comment '顺序' ,
|
|
total_rule varchar(500) comment '合计规则' ,
|
|
count_rule varchar(500) comment '计数规则' ,
|
|
unit_type int default 2 comment '统计单位'
|
|
)
|
|
;
|
|
|
|
create index idx_report_tenant_key on hrsa_sub_table_item(tenant_key)
|
|
;
|
|
|
|
create index idx_tk_table_dt_517df716 on hrsa_sub_table_item(tenant_key,delete_type,table_id,creator)
|
|
; |