/*==============================================================*/
/* DBMS name: ORACLE Version 10g */
/* Created on: 2010-10-13 14:56:47 */
/*==============================================================*/
alter table "F_FormData"
drop constraint FK_F_FORMDA_RELATIONS_F_CUSTOM;
alter table "F_Opinion"
drop constraint FK_F_OPINIO_RELATIONS_F_CUSTOM;
alter table "F_WorkFlowForm"
drop constraint FK_F_WORKFL_RELATIONS_F_CUSTOM;
drop table "F_CustomForm" cascade constraints;
drop index "Relationship_2_FK";
drop table "F_FormData" cascade constraints;
drop index "Relationship_1_FK";
drop table "F_Opinion" cascade constraints;
drop table "F_ProcessFile" cascade constraints;
drop index "Relationship_3_FK";
drop table "F_WorkFlowForm" cascade constraints;
/*==============================================================*/
/* Table: "F_CustomForm" */
/*==============================================================*/
create table "F_CustomForm" (
"fid" VARCHAR2(32) not null,
"formname" VARCHAR2(20) not null,
"formpath" VARCHAR2(100) not null,
"createtime" DATE not null,
"creater" VARCHAR2(20) not null,
"formcontent" VARCHAR2(200) not null,
constraint PK_F_CUSTOMFORM primary key ("fid")
);
/*==============================================================*/
/* Table: "F_FormData" */
/*==============================================================*/
create table "F_FormData" (
"did" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"datatype" VARCHAR2(100) not null,
"dataname" VARCHAR2(20) not null,
"datavalue" VARCHAR2(20),
"piid" VARCHAR2(32) not null,
constraint PK_F_FORMDATA primary key ("did")
);
/*==============================================================*/
/* Index: "Relationship_2_FK" */
/*==============================================================*/
create index "Relationship_2_FK" on "F_FormData" (
"fid" ASC
);
/*==============================================================*/
/* Table: "F_Opinion" */
/*==============================================================*/
create table "F_Opinion" (
"oid" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"creater" VARCHAR2(20) not null,
"createtime" DATE not null,
"context" VARCHAR2(200),
"piId" VARCHAR2(32),
constraint PK_F_OPINION primary key ("oid")
);
/*==============================================================*/
/* Index: "Relationship_1_FK" */
/*==============================================================*/
create index "Relationship_1_FK" on "F_Opinion" (
"fid" ASC
);
/*==============================================================*/
/* Table: "F_ProcessFile" */
/*==============================================================*/
create table "F_ProcessFile" (
"id" VARCHAR2(32) not null,
"processfielname" VARCHAR2(20) not null,
"path" VARCHAR2(100),
"processfilesate" VARCHAR2(2) not null,
"workflowid" VARCHAR2(32),
constraint PK_F_PROCESSFILE primary key ("id")
);
/*==============================================================*/
/* Table: "F_WorkFlowForm" */
/*==============================================================*/
create table "F_WorkFlowForm" (
"wfid" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"workflowid" VARCHAR2(32) not null,
constraint PK_F_WORKFLOWFORM primary key ("wfid")
);
/*==============================================================*/
/* Index: "Relationship_3_FK" */
/*==============================================================*/
create index "Relationship_3_FK" on "F_WorkFlowForm" (
"fid" ASC
);
alter table "F_FormData"
add constraint FK_F_FORMDA_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");
alter table "F_Opinion"
add constraint FK_F_OPINIO_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");
alter table "F_WorkFlowForm"
add constraint FK_F_WORKFL_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");
/* DBMS name: ORACLE Version 10g */
/* Created on: 2010-10-13 14:56:47 */
/*==============================================================*/
alter table "F_FormData"
drop constraint FK_F_FORMDA_RELATIONS_F_CUSTOM;
alter table "F_Opinion"
drop constraint FK_F_OPINIO_RELATIONS_F_CUSTOM;
alter table "F_WorkFlowForm"
drop constraint FK_F_WORKFL_RELATIONS_F_CUSTOM;
drop table "F_CustomForm" cascade constraints;
drop index "Relationship_2_FK";
drop table "F_FormData" cascade constraints;
drop index "Relationship_1_FK";
drop table "F_Opinion" cascade constraints;
drop table "F_ProcessFile" cascade constraints;
drop index "Relationship_3_FK";
drop table "F_WorkFlowForm" cascade constraints;
/*==============================================================*/
/* Table: "F_CustomForm" */
/*==============================================================*/
create table "F_CustomForm" (
"fid" VARCHAR2(32) not null,
"formname" VARCHAR2(20) not null,
"formpath" VARCHAR2(100) not null,
"createtime" DATE not null,
"creater" VARCHAR2(20) not null,
"formcontent" VARCHAR2(200) not null,
constraint PK_F_CUSTOMFORM primary key ("fid")
);
/*==============================================================*/
/* Table: "F_FormData" */
/*==============================================================*/
create table "F_FormData" (
"did" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"datatype" VARCHAR2(100) not null,
"dataname" VARCHAR2(20) not null,
"datavalue" VARCHAR2(20),
"piid" VARCHAR2(32) not null,
constraint PK_F_FORMDATA primary key ("did")
);
/*==============================================================*/
/* Index: "Relationship_2_FK" */
/*==============================================================*/
create index "Relationship_2_FK" on "F_FormData" (
"fid" ASC
);
/*==============================================================*/
/* Table: "F_Opinion" */
/*==============================================================*/
create table "F_Opinion" (
"oid" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"creater" VARCHAR2(20) not null,
"createtime" DATE not null,
"context" VARCHAR2(200),
"piId" VARCHAR2(32),
constraint PK_F_OPINION primary key ("oid")
);
/*==============================================================*/
/* Index: "Relationship_1_FK" */
/*==============================================================*/
create index "Relationship_1_FK" on "F_Opinion" (
"fid" ASC
);
/*==============================================================*/
/* Table: "F_ProcessFile" */
/*==============================================================*/
create table "F_ProcessFile" (
"id" VARCHAR2(32) not null,
"processfielname" VARCHAR2(20) not null,
"path" VARCHAR2(100),
"processfilesate" VARCHAR2(2) not null,
"workflowid" VARCHAR2(32),
constraint PK_F_PROCESSFILE primary key ("id")
);
/*==============================================================*/
/* Table: "F_WorkFlowForm" */
/*==============================================================*/
create table "F_WorkFlowForm" (
"wfid" VARCHAR2(32) not null,
"fid" VARCHAR2(32),
"workflowid" VARCHAR2(32) not null,
constraint PK_F_WORKFLOWFORM primary key ("wfid")
);
/*==============================================================*/
/* Index: "Relationship_3_FK" */
/*==============================================================*/
create index "Relationship_3_FK" on "F_WorkFlowForm" (
"fid" ASC
);
alter table "F_FormData"
add constraint FK_F_FORMDA_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");
alter table "F_Opinion"
add constraint FK_F_OPINIO_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");
alter table "F_WorkFlowForm"
add constraint FK_F_WORKFL_RELATIONS_F_CUSTOM foreign key ("fid")
references "F_CustomForm" ("fid");