create table hrsa_statreportlogs_detail
(
  id number primary key ,
  create_time date,
  update_time date,
  creator number,
  delete_type int default 0,
  tenant_key varchar2(10),
  uuid varchar2(36) not null,
  mainid varchar2(36) not null,
  dataid varchar2(50) not null,
  belongdataid varchar2(50) not null,
  tablename varchar2(200) not null,
  tablenamelabelid varchar2(50) default '-1' not null,
  tablenamedesc varchar2(50) not null,
  fieldname varchar2(200) not null,
  fieldnamelabelid varchar2(50) default '-1' not null,
  newvalue clob not null,
  oldvalue clob not null,
  newrealvalue clob not null,
  oldrealvalue clob not null,
  fielddesc varchar2(200) not null,
  showorder int not null,
  isdetail int default 0 not null
)
/

create index idx_tenant_4fd0f4bc on hrsa_statreportlogs_detail(tenant_key)
/

create index idx_del_up_e798e3ef on hrsa_statreportlogs_detail(delete_type,update_time)
/

create table hrsa_statreportlogs
(
  id number primary key ,
  create_time date,
  update_time date,
  creator number,
  delete_type int default 0,
  tenant_key varchar2(10),
  uuid varchar2(36) not null,
  log_date date not null,
  device varchar2(500) not null,
  log_operator number not null,
  operatorname varchar2(100),
  targetid number default '-1' not null,
  targetname clob not null,
  modulename varchar2(100) not null,
  functionname varchar2(100) not null,
  interfacename varchar2(100) not null,
  requesturl varchar2(200) not null,
  requesturi varchar2(200) not null,
  operatetype varchar2(50) not null,
  operatetypename varchar2(100) not null,
  operatedesc varchar2(3000) not null,
  params clob not null,
  belongmainid varchar2(36) not null,
  clientip varchar2(50) not null,
  groupid varchar2(50) not null,
  groupnamelabel varchar2(1000) not null,
  redoservice varchar2(200) not null,
  redocontext clob not null,
  cancelservice varchar2(200) not null,
  cancelcontext clob not null,
  totalruntime number default '0' not null,
  mainruntime number default '0' not null,
  log_result varchar2(100) not null,
  fromterminal varchar2(100) not null,
  resultdesc clob not null,
  old_content varchar2(3000) not null,
  link_type varchar2(20) not null,
  link_id number default '0' not null,
  old_link_id number default '0' not null
)
/

create index idx_tenan_0ad78df3 on hrsa_statreportlogs(tenant_key)
/

create index idx_del_u_7c93862b on hrsa_statreportlogs(delete_type,update_time)
/