Terry.Li-彬

虚其心,可解天下之问;专其心,可治天下之学;静其心,可悟天下之理;恒其心,可成天下之业。

  BlogJava :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  143 随笔 :: 344 文章 :: 130 评论 :: 0 Trackbacks

/*
SQLyog Enterprise - MySQL GUI v5.02
Host - 5.0.27-community-nt : Database - jbpm
*********************************************************************
Server version : 5.0.27-community-nt
*/


create database if not exists `jbpm`;

USE `jbpm`;

SET FOREIGN_KEY_CHECKS=0;

/*Table structure for table `jbpm_action` */

DROP TABLE IF EXISTS `jbpm_action`;

CREATE TABLE `jbpm_action` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `class` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `ISPROPAGATIONALLOWED_` integer(1) default NULL,
  `ACTIONEXPRESSION_` varchar(255) default NULL,
  `ISASYNC_` integer(1) default NULL,
  `REFERENCEDACTION_` bigint(20) default NULL,
  `ACTIONDELEGATION_` bigint(20) default NULL,
  `EVENT_` bigint(20) default NULL,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `TIMERNAME_` varchar(255) default NULL,
  `DUEDATE_` varchar(255) default NULL,
  `REPEAT_` varchar(255) default NULL,
  `TRANSITIONNAME_` varchar(255) default NULL,
  `TIMERACTION_` bigint(20) default NULL,
  `EXPRESSION_` mediumtext,
  `EVENTINDEX_` int(11) default NULL,
  `EXCEPTIONHANDLER_` bigint(20) default NULL,
  `EXCEPTIONHANDLERINDEX_` int(11) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_ACTION_EVENT` (`EVENT_`),
  KEY `IDX_ACTION_ACTNDL` (`ACTIONDELEGATION_`),
  KEY `IDX_ACTION_PROCDF` (`PROCESSDEFINITION_`),
  KEY `FK_ACTION_EVENT` (`EVENT_`),
  KEY `FK_ACTION_EXPTHDL` (`EXCEPTIONHANDLER_`),
  KEY `FK_ACTION_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_CRTETIMERACT_TA` (`TIMERACTION_`),
  KEY `FK_ACTION_ACTNDEL` (`ACTIONDELEGATION_`),
  KEY `FK_ACTION_REFACT` (`REFERENCEDACTION_`),
  CONSTRAINT `FK_ACTION_REFACT` FOREIGN KEY (`REFERENCEDACTION_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_ACTION_ACTNDEL` FOREIGN KEY (`ACTIONDELEGATION_`) REFERENCES `jbpm_delegation` (`ID_`),
  CONSTRAINT `FK_ACTION_EVENT` FOREIGN KEY (`EVENT_`) REFERENCES `jbpm_event` (`ID_`),
  CONSTRAINT `FK_ACTION_EXPTHDL` FOREIGN KEY (`EXCEPTIONHANDLER_`) REFERENCES `jbpm_exceptionhandler` (`ID_`),
  CONSTRAINT `FK_ACTION_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_CRTETIMERACT_TA` FOREIGN KEY (`TIMERACTION_`) REFERENCES `jbpm_action` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_bytearray` */

DROP TABLE IF EXISTS `jbpm_bytearray`;

CREATE TABLE `jbpm_bytearray` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `NAME_` varchar(255) default NULL,
  `FILEDEFINITION_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_BYTEARR_FILDEF` (`FILEDEFINITION_`),
  CONSTRAINT `FK_BYTEARR_FILDEF` FOREIGN KEY (`FILEDEFINITION_`) REFERENCES `jbpm_moduledefinition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_byteblock` */

DROP TABLE IF EXISTS `jbpm_byteblock`;

CREATE TABLE `jbpm_byteblock` (
  `PROCESSFILE_` bigint(20) NOT NULL,
  `BYTES_` blob,
  `INDEX_` int(11) NOT NULL,
  PRIMARY KEY  (`PROCESSFILE_`,`INDEX_`),
  KEY `FK_BYTEBLOCK_FILE` (`PROCESSFILE_`),
  CONSTRAINT `FK_BYTEBLOCK_FILE` FOREIGN KEY (`PROCESSFILE_`) REFERENCES `jbpm_bytearray` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_comment` */

DROP TABLE IF EXISTS `jbpm_comment`;

CREATE TABLE `jbpm_comment` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `ACTORID_` varchar(255) default NULL,
  `TIME_` datetime default NULL,
  `MESSAGE_` mediumtext,
  `TOKEN_` bigint(20) default NULL,
  `TASKINSTANCE_` bigint(20) default NULL,
  `TOKENINDEX_` int(11) default NULL,
  `TASKINSTANCEINDEX_` int(11) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_COMMENT_TOKEN` (`TOKEN_`),
  KEY `IDX_COMMENT_TSK` (`TASKINSTANCE_`),
  KEY `FK_COMMENT_TOKEN` (`TOKEN_`),
  KEY `FK_COMMENT_TSK` (`TASKINSTANCE_`),
  CONSTRAINT `FK_COMMENT_TSK` FOREIGN KEY (`TASKINSTANCE_`) REFERENCES `jbpm_taskinstance` (`ID_`),
  CONSTRAINT `FK_COMMENT_TOKEN` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_decisionconditions` */

DROP TABLE IF EXISTS `jbpm_decisionconditions`;

CREATE TABLE `jbpm_decisionconditions` (
  `DECISION_` bigint(20) NOT NULL,
  `TRANSITIONNAME_` varchar(255) default NULL,
  `EXPRESSION_` varchar(255) default NULL,
  `INDEX_` int(11) NOT NULL,
  PRIMARY KEY  (`DECISION_`,`INDEX_`),
  KEY `FK_DECCOND_DEC` (`DECISION_`),
  CONSTRAINT `FK_DECCOND_DEC` FOREIGN KEY (`DECISION_`) REFERENCES `jbpm_node` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_delegation` */

DROP TABLE IF EXISTS `jbpm_delegation`;

CREATE TABLE `jbpm_delegation` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASSNAME_` mediumtext,
  `CONFIGURATION_` mediumtext,
  `CONFIGTYPE_` varchar(255) default NULL,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_DELEG_PRCD` (`PROCESSDEFINITION_`),
  KEY `FK_DELEGATION_PRCD` (`PROCESSDEFINITION_`),
  CONSTRAINT `FK_DELEGATION_PRCD` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_event` */

DROP TABLE IF EXISTS `jbpm_event`;

CREATE TABLE `jbpm_event` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `EVENTTYPE_` varchar(255) default NULL,
  `TYPE_` char(1) default NULL,
  `GRAPHELEMENT_` bigint(20) default NULL,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `NODE_` bigint(20) default NULL,
  `TRANSITION_` bigint(20) default NULL,
  `TASK_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_EVENT_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_EVENT_NODE` (`NODE_`),
  KEY `FK_EVENT_TRANS` (`TRANSITION_`),
  KEY `FK_EVENT_TASK` (`TASK_`),
  CONSTRAINT `FK_EVENT_TASK` FOREIGN KEY (`TASK_`) REFERENCES `jbpm_task` (`ID_`),
  CONSTRAINT `FK_EVENT_NODE` FOREIGN KEY (`NODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_EVENT_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_EVENT_TRANS` FOREIGN KEY (`TRANSITION_`) REFERENCES `jbpm_transition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_exceptionhandler` */

DROP TABLE IF EXISTS `jbpm_exceptionhandler`;

CREATE TABLE `jbpm_exceptionhandler` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `EXCEPTIONCLASSNAME_` text,
  `TYPE_` char(1) default NULL,
  `GRAPHELEMENT_` bigint(20) default NULL,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `GRAPHELEMENTINDEX_` int(11) default NULL,
  `NODE_` bigint(20) default NULL,
  `TRANSITION_` bigint(20) default NULL,
  `TASK_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_id_group` */

DROP TABLE IF EXISTS `jbpm_id_group`;

CREATE TABLE `jbpm_id_group` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `TYPE_` varchar(255) default NULL,
  `PARENT_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_ID_GRP_PARENT` (`PARENT_`),
  CONSTRAINT `FK_ID_GRP_PARENT` FOREIGN KEY (`PARENT_`) REFERENCES `jbpm_id_group` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_id_membership` */

DROP TABLE IF EXISTS `jbpm_id_membership`;

CREATE TABLE `jbpm_id_membership` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `ROLE_` varchar(255) default NULL,
  `USER_` bigint(20) default NULL,
  `GROUP_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_ID_MEMSHIP_GRP` (`GROUP_`),
  KEY `FK_ID_MEMSHIP_USR` (`USER_`),
  CONSTRAINT `FK_ID_MEMSHIP_USR` FOREIGN KEY (`USER_`) REFERENCES `jbpm_id_user` (`ID_`),
  CONSTRAINT `FK_ID_MEMSHIP_GRP` FOREIGN KEY (`GROUP_`) REFERENCES `jbpm_id_group` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_id_permissions` */

DROP TABLE IF EXISTS `jbpm_id_permissions`;

CREATE TABLE `jbpm_id_permissions` (
  `ENTITY_` bigint(20) NOT NULL,
  `CLASS_` varchar(255) default NULL,
  `NAME_` varchar(255) default NULL,
  `ACTION_` varchar(255) default NULL
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_id_user` */

DROP TABLE IF EXISTS `jbpm_id_user`;

CREATE TABLE `jbpm_id_user` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `EMAIL_` varchar(255) default NULL,
  `PASSWORD_` varchar(255) default NULL,
  PRIMARY KEY  (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_job` */

DROP TABLE IF EXISTS `jbpm_job`;

CREATE TABLE `jbpm_job` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `VERSION_` int(11) NOT NULL,
  `DUEDATE_` datetime default NULL,
  `PROCESSINSTANCE_` bigint(20) default NULL,
  `TOKEN_` bigint(20) default NULL,
  `TASKINSTANCE_` bigint(20) default NULL,
  `ISSUSPENDED_` integer(1) default NULL,
  `ISEXCLUSIVE_` integer(1) default NULL,
  `LOCKOWNER_` varchar(255) default NULL,
  `LOCKTIME_` datetime default NULL,
  `EXCEPTION_` mediumtext,
  `RETRIES_` int(11) default NULL,
  `NAME_` varchar(255) default NULL,
  `REPEAT_` varchar(255) default NULL,
  `TRANSITIONNAME_` varchar(255) default NULL,
  `ACTION_` bigint(20) default NULL,
  `GRAPHELEMENTTYPE_` varchar(255) default NULL,
  `GRAPHELEMENT_` bigint(20) default NULL,
  `NODE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_JOB_TSKINST` (`TASKINSTANCE_`),
  KEY `IDX_JOB_PRINST` (`PROCESSINSTANCE_`),
  KEY `IDX_JOB_TOKEN` (`TOKEN_`),
  KEY `FK_JOB_TOKEN` (`TOKEN_`),
  KEY `FK_JOB_NODE` (`NODE_`),
  KEY `FK_JOB_PRINST` (`PROCESSINSTANCE_`),
  KEY `FK_JOB_ACTION` (`ACTION_`),
  KEY `FK_JOB_TSKINST` (`TASKINSTANCE_`),
  CONSTRAINT `FK_JOB_TSKINST` FOREIGN KEY (`TASKINSTANCE_`) REFERENCES `jbpm_taskinstance` (`ID_`),
  CONSTRAINT `FK_JOB_ACTION` FOREIGN KEY (`ACTION_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_JOB_NODE` FOREIGN KEY (`NODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_JOB_PRINST` FOREIGN KEY (`PROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`),
  CONSTRAINT `FK_JOB_TOKEN` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_log` */

DROP TABLE IF EXISTS `jbpm_log`;

CREATE TABLE `jbpm_log` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `INDEX_` int(11) default NULL,
  `DATE_` datetime default NULL,
  `TOKEN_` bigint(20) default NULL,
  `PARENT_` bigint(20) default NULL,
  `MESSAGE_` mediumtext,
  `EXCEPTION_` mediumtext,
  `ACTION_` bigint(20) default NULL,
  `NODE_` bigint(20) default NULL,
  `ENTER_` datetime default NULL,
  `LEAVE_` datetime default NULL,
  `DURATION_` bigint(20) default NULL,
  `NEWLONGVALUE_` bigint(20) default NULL,
  `TRANSITION_` bigint(20) default NULL,
  `CHILD_` bigint(20) default NULL,
  `SOURCENODE_` bigint(20) default NULL,
  `DESTINATIONNODE_` bigint(20) default NULL,
  `VARIABLEINSTANCE_` bigint(20) default NULL,
  `OLDBYTEARRAY_` bigint(20) default NULL,
  `NEWBYTEARRAY_` bigint(20) default NULL,
  `OLDDATEVALUE_` datetime default NULL,
  `NEWDATEVALUE_` datetime default NULL,
  `OLDDOUBLEVALUE_` double default NULL,
  `NEWDOUBLEVALUE_` double default NULL,
  `OLDLONGIDCLASS_` varchar(255) default NULL,
  `OLDLONGIDVALUE_` bigint(20) default NULL,
  `NEWLONGIDCLASS_` varchar(255) default NULL,
  `NEWLONGIDVALUE_` bigint(20) default NULL,
  `OLDSTRINGIDCLASS_` varchar(255) default NULL,
  `OLDSTRINGIDVALUE_` varchar(255) default NULL,
  `NEWSTRINGIDCLASS_` varchar(255) default NULL,
  `NEWSTRINGIDVALUE_` varchar(255) default NULL,
  `OLDLONGVALUE_` bigint(20) default NULL,
  `OLDSTRINGVALUE_` mediumtext,
  `NEWSTRINGVALUE_` mediumtext,
  `TASKINSTANCE_` bigint(20) default NULL,
  `TASKACTORID_` varchar(255) default NULL,
  `TASKOLDACTORID_` varchar(255) default NULL,
  `SWIMLANEINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_LOG_SOURCENODE` (`SOURCENODE_`),
  KEY `FK_LOG_TOKEN` (`TOKEN_`),
  KEY `FK_LOG_OLDBYTES` (`OLDBYTEARRAY_`),
  KEY `FK_LOG_NEWBYTES` (`NEWBYTEARRAY_`),
  KEY `FK_LOG_CHILDTOKEN` (`CHILD_`),
  KEY `FK_LOG_DESTNODE` (`DESTINATIONNODE_`),
  KEY `FK_LOG_TASKINST` (`TASKINSTANCE_`),
  KEY `FK_LOG_SWIMINST` (`SWIMLANEINSTANCE_`),
  KEY `FK_LOG_PARENT` (`PARENT_`),
  KEY `FK_LOG_NODE` (`NODE_`),
  KEY `FK_LOG_ACTION` (`ACTION_`),
  KEY `FK_LOG_VARINST` (`VARIABLEINSTANCE_`),
  KEY `FK_LOG_TRANSITION` (`TRANSITION_`),
  CONSTRAINT `FK_LOG_TRANSITION` FOREIGN KEY (`TRANSITION_`) REFERENCES `jbpm_transition` (`ID_`),
  CONSTRAINT `FK_LOG_ACTION` FOREIGN KEY (`ACTION_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_LOG_CHILDTOKEN` FOREIGN KEY (`CHILD_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_LOG_DESTNODE` FOREIGN KEY (`DESTINATIONNODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_LOG_NEWBYTES` FOREIGN KEY (`NEWBYTEARRAY_`) REFERENCES `jbpm_bytearray` (`ID_`),
  CONSTRAINT `FK_LOG_NODE` FOREIGN KEY (`NODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_LOG_OLDBYTES` FOREIGN KEY (`OLDBYTEARRAY_`) REFERENCES `jbpm_bytearray` (`ID_`),
  CONSTRAINT `FK_LOG_PARENT` FOREIGN KEY (`PARENT_`) REFERENCES `jbpm_log` (`ID_`),
  CONSTRAINT `FK_LOG_SOURCENODE` FOREIGN KEY (`SOURCENODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_LOG_SWIMINST` FOREIGN KEY (`SWIMLANEINSTANCE_`) REFERENCES `jbpm_swimlaneinstance` (`ID_`),
  CONSTRAINT `FK_LOG_TASKINST` FOREIGN KEY (`TASKINSTANCE_`) REFERENCES `jbpm_taskinstance` (`ID_`),
  CONSTRAINT `FK_LOG_TOKEN` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_LOG_VARINST` FOREIGN KEY (`VARIABLEINSTANCE_`) REFERENCES `jbpm_variableinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_moduledefinition` */

DROP TABLE IF EXISTS `jbpm_moduledefinition`;

CREATE TABLE `jbpm_moduledefinition` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` mediumtext,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `STARTTASK_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_MODDEF_PROCDF` (`PROCESSDEFINITION_`),
  KEY `FK_TSKDEF_START` (`STARTTASK_`),
  KEY `FK_MODDEF_PROCDEF` (`PROCESSDEFINITION_`),
  CONSTRAINT `FK_MODDEF_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_TSKDEF_START` FOREIGN KEY (`STARTTASK_`) REFERENCES `jbpm_task` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_moduleinstance` */

DROP TABLE IF EXISTS `jbpm_moduleinstance`;

CREATE TABLE `jbpm_moduleinstance` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `VERSION_` int(11) NOT NULL,
  `PROCESSINSTANCE_` bigint(20) default NULL,
  `TASKMGMTDEFINITION_` bigint(20) default NULL,
  `NAME_` varchar(255) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_MODINST_PRINST` (`PROCESSINSTANCE_`),
  KEY `FK_TASKMGTINST_TMD` (`TASKMGMTDEFINITION_`),
  KEY `FK_MODINST_PRCINST` (`PROCESSINSTANCE_`),
  CONSTRAINT `FK_MODINST_PRCINST` FOREIGN KEY (`PROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`),
  CONSTRAINT `FK_TASKMGTINST_TMD` FOREIGN KEY (`TASKMGMTDEFINITION_`) REFERENCES `jbpm_moduledefinition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_node` */

DROP TABLE IF EXISTS `jbpm_node`;

CREATE TABLE `jbpm_node` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `DESCRIPTION_` mediumtext,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `ISASYNC_` integer(1) default NULL,
  `ISASYNCEXCL_` integer(1) default NULL,
  `ACTION_` bigint(20) default NULL,
  `SUPERSTATE_` bigint(20) default NULL,
  `SUBPROCNAME_` varchar(255) default NULL,
  `SUBPROCESSDEFINITION_` bigint(20) default NULL,
  `DECISIONEXPRESSION_` varchar(255) default NULL,
  `DECISIONDELEGATION` bigint(20) default NULL,
  `SCRIPT_` bigint(20) default NULL,
  `SIGNAL_` int(11) default NULL,
  `CREATETASKS_` integer(1) default NULL,
  `ENDTASKS_` integer(1) default NULL,
  `NODECOLLECTIONINDEX_` int(11) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_PSTATE_SBPRCDEF` (`SUBPROCESSDEFINITION_`),
  KEY `IDX_NODE_SUPRSTATE` (`SUPERSTATE_`),
  KEY `IDX_NODE_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `IDX_NODE_ACTION` (`ACTION_`),
  KEY `FK_PROCST_SBPRCDEF` (`SUBPROCESSDEFINITION_`),
  KEY `FK_NODE_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_NODE_SCRIPT` (`SCRIPT_`),
  KEY `FK_NODE_ACTION` (`ACTION_`),
  KEY `FK_DECISION_DELEG` (`DECISIONDELEGATION`),
  KEY `FK_NODE_SUPERSTATE` (`SUPERSTATE_`),
  CONSTRAINT `FK_NODE_SUPERSTATE` FOREIGN KEY (`SUPERSTATE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_DECISION_DELEG` FOREIGN KEY (`DECISIONDELEGATION`) REFERENCES `jbpm_delegation` (`ID_`),
  CONSTRAINT `FK_NODE_ACTION` FOREIGN KEY (`ACTION_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_NODE_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_NODE_SCRIPT` FOREIGN KEY (`SCRIPT_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_PROCST_SBPRCDEF` FOREIGN KEY (`SUBPROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_pooledactor` */

DROP TABLE IF EXISTS `jbpm_pooledactor`;

CREATE TABLE `jbpm_pooledactor` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `ACTORID_` varchar(255) default NULL,
  `SWIMLANEINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_PLDACTR_ACTID` (`ACTORID_`),
  KEY `IDX_TSKINST_SWLANE` (`SWIMLANEINSTANCE_`),
  KEY `FK_POOLEDACTOR_SLI` (`SWIMLANEINSTANCE_`),
  CONSTRAINT `FK_POOLEDACTOR_SLI` FOREIGN KEY (`SWIMLANEINSTANCE_`) REFERENCES `jbpm_swimlaneinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_processdefinition` */

DROP TABLE IF EXISTS `jbpm_processdefinition`;

CREATE TABLE `jbpm_processdefinition` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `DESCRIPTION_` mediumtext,
  `VERSION_` int(11) default NULL,
  `ISTERMINATIONIMPLICIT_` integer(1) default NULL,
  `STARTSTATE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_PROCDEF_STRTST` (`STARTSTATE_`),
  KEY `FK_PROCDEF_STRTSTA` (`STARTSTATE_`),
  CONSTRAINT `FK_PROCDEF_STRTSTA` FOREIGN KEY (`STARTSTATE_`) REFERENCES `jbpm_node` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_processinstance` */

DROP TABLE IF EXISTS `jbpm_processinstance`;

CREATE TABLE `jbpm_processinstance` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `KEY_` varchar(255) default NULL,
  `START_` datetime default NULL,
  `END_` datetime default NULL,
  `ISSUSPENDED_` integer(1) default NULL,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `ROOTTOKEN_` bigint(20) default NULL,
  `SUPERPROCESSTOKEN_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  UNIQUE KEY `KEY_` (`KEY_`,`PROCESSDEFINITION_`),
  KEY `IDX_PROCIN_ROOTTK` (`ROOTTOKEN_`),
  KEY `IDX_PROCIN_SPROCTK` (`SUPERPROCESSTOKEN_`),
  KEY `IDX_PROCIN_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_PROCIN_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_PROCIN_ROOTTKN` (`ROOTTOKEN_`),
  KEY `FK_PROCIN_SPROCTKN` (`SUPERPROCESSTOKEN_`),
  CONSTRAINT `FK_PROCIN_SPROCTKN` FOREIGN KEY (`SUPERPROCESSTOKEN_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_PROCIN_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_PROCIN_ROOTTKN` FOREIGN KEY (`ROOTTOKEN_`) REFERENCES `jbpm_token` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_runtimeaction` */

DROP TABLE IF EXISTS `jbpm_runtimeaction`;

CREATE TABLE `jbpm_runtimeaction` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `EVENTTYPE_` varchar(255) default NULL,
  `TYPE_` char(1) default NULL,
  `GRAPHELEMENT_` bigint(20) default NULL,
  `PROCESSINSTANCE_` bigint(20) default NULL,
  `ACTION_` bigint(20) default NULL,
  `PROCESSINSTANCEINDEX_` int(11) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_RTACTN_PRCINST` (`PROCESSINSTANCE_`),
  KEY `IDX_RTACTN_ACTION` (`ACTION_`),
  KEY `FK_RTACTN_PROCINST` (`PROCESSINSTANCE_`),
  KEY `FK_RTACTN_ACTION` (`ACTION_`),
  CONSTRAINT `FK_RTACTN_ACTION` FOREIGN KEY (`ACTION_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_RTACTN_PROCINST` FOREIGN KEY (`PROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_swimlane` */

DROP TABLE IF EXISTS `jbpm_swimlane`;

CREATE TABLE `jbpm_swimlane` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `NAME_` varchar(255) default NULL,
  `ACTORIDEXPRESSION_` varchar(255) default NULL,
  `POOLEDACTORSEXPRESSION_` varchar(255) default NULL,
  `ASSIGNMENTDELEGATION_` bigint(20) default NULL,
  `TASKMGMTDEFINITION_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_SWL_ASSDEL` (`ASSIGNMENTDELEGATION_`),
  KEY `FK_SWL_TSKMGMTDEF` (`TASKMGMTDEFINITION_`),
  CONSTRAINT `FK_SWL_TSKMGMTDEF` FOREIGN KEY (`TASKMGMTDEFINITION_`) REFERENCES `jbpm_moduledefinition` (`ID_`),
  CONSTRAINT `FK_SWL_ASSDEL` FOREIGN KEY (`ASSIGNMENTDELEGATION_`) REFERENCES `jbpm_delegation` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_swimlaneinstance` */

DROP TABLE IF EXISTS `jbpm_swimlaneinstance`;

CREATE TABLE `jbpm_swimlaneinstance` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `ACTORID_` varchar(255) default NULL,
  `SWIMLANE_` bigint(20) default NULL,
  `TASKMGMTINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_SWIMLINST_SL` (`SWIMLANE_`),
  KEY `FK_SWIMLANEINST_TM` (`TASKMGMTINSTANCE_`),
  KEY `FK_SWIMLANEINST_SL` (`SWIMLANE_`),
  CONSTRAINT `FK_SWIMLANEINST_SL` FOREIGN KEY (`SWIMLANE_`) REFERENCES `jbpm_swimlane` (`ID_`),
  CONSTRAINT `FK_SWIMLANEINST_TM` FOREIGN KEY (`TASKMGMTINSTANCE_`) REFERENCES `jbpm_moduleinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_task` */

DROP TABLE IF EXISTS `jbpm_task`;

CREATE TABLE `jbpm_task` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `NAME_` varchar(255) default NULL,
  `DESCRIPTION_` mediumtext,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `ISBLOCKING_` integer(1) default NULL,
  `ISSIGNALLING_` integer(1) default NULL,
  `CONDITION_` varchar(255) default NULL,
  `DUEDATE_` varchar(255) default NULL,
  `PRIORITY_` int(11) default NULL,
  `ACTORIDEXPRESSION_` varchar(255) default NULL,
  `POOLEDACTORSEXPRESSION_` varchar(255) default NULL,
  `TASKMGMTDEFINITION_` bigint(20) default NULL,
  `TASKNODE_` bigint(20) default NULL,
  `STARTSTATE_` bigint(20) default NULL,
  `ASSIGNMENTDELEGATION_` bigint(20) default NULL,
  `SWIMLANE_` bigint(20) default NULL,
  `TASKCONTROLLER_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_TASK_TSKNODE` (`TASKNODE_`),
  KEY `IDX_TASK_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `IDX_TASK_TASKMGTDF` (`TASKMGMTDEFINITION_`),
  KEY `FK_TSK_TSKCTRL` (`TASKCONTROLLER_`),
  KEY `FK_TASK_ASSDEL` (`ASSIGNMENTDELEGATION_`),
  KEY `FK_TASK_TASKNODE` (`TASKNODE_`),
  KEY `FK_TASK_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_TASK_STARTST` (`STARTSTATE_`),
  KEY `FK_TASK_TASKMGTDEF` (`TASKMGMTDEFINITION_`),
  KEY `FK_TASK_SWIMLANE` (`SWIMLANE_`),
  CONSTRAINT `FK_TASK_SWIMLANE` FOREIGN KEY (`SWIMLANE_`) REFERENCES `jbpm_swimlane` (`ID_`),
  CONSTRAINT `FK_TASK_ASSDEL` FOREIGN KEY (`ASSIGNMENTDELEGATION_`) REFERENCES `jbpm_delegation` (`ID_`),
  CONSTRAINT `FK_TASK_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`),
  CONSTRAINT `FK_TASK_STARTST` FOREIGN KEY (`STARTSTATE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_TASK_TASKMGTDEF` FOREIGN KEY (`TASKMGMTDEFINITION_`) REFERENCES `jbpm_moduledefinition` (`ID_`),
  CONSTRAINT `FK_TASK_TASKNODE` FOREIGN KEY (`TASKNODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_TSK_TSKCTRL` FOREIGN KEY (`TASKCONTROLLER_`) REFERENCES `jbpm_taskcontroller` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_taskactorpool` */

DROP TABLE IF EXISTS `jbpm_taskactorpool`;

CREATE TABLE `jbpm_taskactorpool` (
  `TASKINSTANCE_` bigint(20) NOT NULL,
  `POOLEDACTOR_` bigint(20) NOT NULL,
  PRIMARY KEY  (`TASKINSTANCE_`,`POOLEDACTOR_`),
  KEY `FK_TSKACTPOL_PLACT` (`POOLEDACTOR_`),
  KEY `FK_TASKACTPL_TSKI` (`TASKINSTANCE_`),
  CONSTRAINT `FK_TASKACTPL_TSKI` FOREIGN KEY (`TASKINSTANCE_`) REFERENCES `jbpm_taskinstance` (`ID_`),
  CONSTRAINT `FK_TSKACTPOL_PLACT` FOREIGN KEY (`POOLEDACTOR_`) REFERENCES `jbpm_pooledactor` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_taskcontroller` */

DROP TABLE IF EXISTS `jbpm_taskcontroller`;

CREATE TABLE `jbpm_taskcontroller` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `TASKCONTROLLERDELEGATION_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_TSKCTRL_DELEG` (`TASKCONTROLLERDELEGATION_`),
  CONSTRAINT `FK_TSKCTRL_DELEG` FOREIGN KEY (`TASKCONTROLLERDELEGATION_`) REFERENCES `jbpm_delegation` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_taskinstance` */

DROP TABLE IF EXISTS `jbpm_taskinstance`;

CREATE TABLE `jbpm_taskinstance` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `VERSION_` int(11) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `DESCRIPTION_` mediumtext,
  `ACTORID_` varchar(255) default NULL,
  `CREATE_` datetime default NULL,
  `START_` datetime default NULL,
  `END_` datetime default NULL,
  `DUEDATE_` datetime default NULL,
  `PRIORITY_` int(11) default NULL,
  `ISCANCELLED_` integer(1) default NULL,
  `ISSUSPENDED_` integer(1) default NULL,
  `ISOPEN_` integer(1) default NULL,
  `ISSIGNALLING_` integer(1) default NULL,
  `ISBLOCKING_` integer(1) default NULL,
  `TASK_` bigint(20) default NULL,
  `TOKEN_` bigint(20) default NULL,
  `PROCINST_` bigint(20) default NULL,
  `SWIMLANINSTANCE_` bigint(20) default NULL,
  `TASKMGMTINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_TASKINST_TOKN` (`TOKEN_`),
  KEY `IDX_TASKINST_TSK` (`TASK_`,`PROCINST_`),
  KEY `IDX_TSKINST_TMINST` (`TASKMGMTINSTANCE_`),
  KEY `IDX_TSKINST_SLINST` (`SWIMLANINSTANCE_`),
  KEY `IDX_TASK_ACTORID` (`ACTORID_`),
  KEY `FK_TSKINS_PRCINS` (`PROCINST_`),
  KEY `FK_TASKINST_TMINST` (`TASKMGMTINSTANCE_`),
  KEY `FK_TASKINST_TOKEN` (`TOKEN_`),
  KEY `FK_TASKINST_SLINST` (`SWIMLANINSTANCE_`),
  KEY `FK_TASKINST_TASK` (`TASK_`),
  CONSTRAINT `FK_TASKINST_TASK` FOREIGN KEY (`TASK_`) REFERENCES `jbpm_task` (`ID_`),
  CONSTRAINT `FK_TASKINST_SLINST` FOREIGN KEY (`SWIMLANINSTANCE_`) REFERENCES `jbpm_swimlaneinstance` (`ID_`),
  CONSTRAINT `FK_TASKINST_TMINST` FOREIGN KEY (`TASKMGMTINSTANCE_`) REFERENCES `jbpm_moduleinstance` (`ID_`),
  CONSTRAINT `FK_TASKINST_TOKEN` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_TSKINS_PRCINS` FOREIGN KEY (`PROCINST_`) REFERENCES `jbpm_processinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_token` */

DROP TABLE IF EXISTS `jbpm_token`;

CREATE TABLE `jbpm_token` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `START_` datetime default NULL,
  `END_` datetime default NULL,
  `NODEENTER_` datetime default NULL,
  `NEXTLOGINDEX_` int(11) default NULL,
  `ISABLETOREACTIVATEPARENT_` integer(1) default NULL,
  `ISTERMINATIONIMPLICIT_` integer(1) default NULL,
  `ISSUSPENDED_` integer(1) default NULL,
  `LOCK_` varchar(255) default NULL,
  `NODE_` bigint(20) default NULL,
  `PROCESSINSTANCE_` bigint(20) default NULL,
  `PARENT_` bigint(20) default NULL,
  `SUBPROCESSINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_TOKEN_PROCIN` (`PROCESSINSTANCE_`),
  KEY `IDX_TOKEN_SUBPI` (`SUBPROCESSINSTANCE_`),
  KEY `IDX_TOKEN_NODE` (`NODE_`),
  KEY `IDX_TOKEN_PARENT` (`PARENT_`),
  KEY `FK_TOKEN_PARENT` (`PARENT_`),
  KEY `FK_TOKEN_NODE` (`NODE_`),
  KEY `FK_TOKEN_PROCINST` (`PROCESSINSTANCE_`),
  KEY `FK_TOKEN_SUBPI` (`SUBPROCESSINSTANCE_`),
  CONSTRAINT `FK_TOKEN_SUBPI` FOREIGN KEY (`SUBPROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`),
  CONSTRAINT `FK_TOKEN_NODE` FOREIGN KEY (`NODE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_TOKEN_PARENT` FOREIGN KEY (`PARENT_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_TOKEN_PROCINST` FOREIGN KEY (`PROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_tokenvariablemap` */

DROP TABLE IF EXISTS `jbpm_tokenvariablemap`;

CREATE TABLE `jbpm_tokenvariablemap` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VERSION_` int(11) NOT NULL,
  `TOKEN_` bigint(20) default NULL,
  `CONTEXTINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_TKVARMAP_CTXT` (`CONTEXTINSTANCE_`),
  KEY `IDX_TKVVARMP_TOKEN` (`TOKEN_`),
  KEY `FK_TKVARMAP_CTXT` (`CONTEXTINSTANCE_`),
  KEY `FK_TKVARMAP_TOKEN` (`TOKEN_`),
  CONSTRAINT `FK_TKVARMAP_TOKEN` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_TKVARMAP_CTXT` FOREIGN KEY (`CONTEXTINSTANCE_`) REFERENCES `jbpm_moduleinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_transition` */

DROP TABLE IF EXISTS `jbpm_transition`;

CREATE TABLE `jbpm_transition` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `NAME_` varchar(255) default NULL,
  `DESCRIPTION_` mediumtext,
  `PROCESSDEFINITION_` bigint(20) default NULL,
  `FROM_` bigint(20) default NULL,
  `TO_` bigint(20) default NULL,
  `CONDITION_` varchar(255) default NULL,
  `FROMINDEX_` int(11) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_TRANSIT_TO` (`TO_`),
  KEY `IDX_TRANSIT_FROM` (`FROM_`),
  KEY `IDX_TRANS_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_TRANSITION_TO` (`TO_`),
  KEY `FK_TRANS_PROCDEF` (`PROCESSDEFINITION_`),
  KEY `FK_TRANSITION_FROM` (`FROM_`),
  CONSTRAINT `FK_TRANSITION_FROM` FOREIGN KEY (`FROM_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_TRANSITION_TO` FOREIGN KEY (`TO_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_TRANS_PROCDEF` FOREIGN KEY (`PROCESSDEFINITION_`) REFERENCES `jbpm_processdefinition` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_variableaccess` */

DROP TABLE IF EXISTS `jbpm_variableaccess`;

CREATE TABLE `jbpm_variableaccess` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `VARIABLENAME_` varchar(255) default NULL,
  `ACCESS_` varchar(255) default NULL,
  `MAPPEDNAME_` varchar(255) default NULL,
  `PROCESSSTATE_` bigint(20) default NULL,
  `TASKCONTROLLER_` bigint(20) default NULL,
  `INDEX_` int(11) default NULL,
  `SCRIPT_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `FK_VARACC_TSKCTRL` (`TASKCONTROLLER_`),
  KEY `FK_VARACC_SCRIPT` (`SCRIPT_`),
  KEY `FK_VARACC_PROCST` (`PROCESSSTATE_`),
  CONSTRAINT `FK_VARACC_PROCST` FOREIGN KEY (`PROCESSSTATE_`) REFERENCES `jbpm_node` (`ID_`),
  CONSTRAINT `FK_VARACC_SCRIPT` FOREIGN KEY (`SCRIPT_`) REFERENCES `jbpm_action` (`ID_`),
  CONSTRAINT `FK_VARACC_TSKCTRL` FOREIGN KEY (`TASKCONTROLLER_`) REFERENCES `jbpm_taskcontroller` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

/*Table structure for table `jbpm_variableinstance` */

DROP TABLE IF EXISTS `jbpm_variableinstance`;

CREATE TABLE `jbpm_variableinstance` (
  `ID_` bigint(20) NOT NULL auto_increment,
  `CLASS_` char(1) NOT NULL,
  `VERSION_` int(11) NOT NULL,
  `NAME_` varchar(255) default NULL,
  `CONVERTER_` char(1) default NULL,
  `TOKEN_` bigint(20) default NULL,
  `TOKENVARIABLEMAP_` bigint(20) default NULL,
  `PROCESSINSTANCE_` bigint(20) default NULL,
  `BYTEARRAYVALUE_` bigint(20) default NULL,
  `DATEVALUE_` datetime default NULL,
  `DOUBLEVALUE_` double default NULL,
  `LONGIDCLASS_` varchar(255) default NULL,
  `LONGVALUE_` bigint(20) default NULL,
  `STRINGIDCLASS_` varchar(255) default NULL,
  `STRINGVALUE_` varchar(255) default NULL,
  `TASKINSTANCE_` bigint(20) default NULL,
  PRIMARY KEY  (`ID_`),
  KEY `IDX_VARINST_TKVARMP` (`TOKENVARIABLEMAP_`),
  KEY `IDX_VARINST_PRCINS` (`PROCESSINSTANCE_`),
  KEY `IDX_VARINST_TK` (`TOKEN_`),
  KEY `FK_VARINST_TK` (`TOKEN_`),
  KEY `FK_VARINST_TKVARMP` (`TOKENVARIABLEMAP_`),
  KEY `FK_VARINST_PRCINST` (`PROCESSINSTANCE_`),
  KEY `FK_VAR_TSKINST` (`TASKINSTANCE_`),
  KEY `FK_BYTEINST_ARRAY` (`BYTEARRAYVALUE_`),
  CONSTRAINT `FK_BYTEINST_ARRAY` FOREIGN KEY (`BYTEARRAYVALUE_`) REFERENCES `jbpm_bytearray` (`ID_`),
  CONSTRAINT `FK_VARINST_PRCINST` FOREIGN KEY (`PROCESSINSTANCE_`) REFERENCES `jbpm_processinstance` (`ID_`),
  CONSTRAINT `FK_VARINST_TK` FOREIGN KEY (`TOKEN_`) REFERENCES `jbpm_token` (`ID_`),
  CONSTRAINT `FK_VARINST_TKVARMP` FOREIGN KEY (`TOKENVARIABLEMAP_`) REFERENCES `jbpm_tokenvariablemap` (`ID_`),
  CONSTRAINT `FK_VAR_TSKINST` FOREIGN KEY (`TASKINSTANCE_`) REFERENCES `jbpm_taskinstance` (`ID_`)
) ENGINE=InnoDB DEFAULT CHARSET=gbk;

SET FOREIGN_KEY_CHECKS=1;

posted on 2007-09-06 18:40 礼物 阅读(1373) 评论(1)  编辑  收藏 所属分类: Jbpm

评论

# re: jbpm oracle 数据库脚本 2010-12-21 09:53 大jj
放屁 这明明是mysql的  回复  更多评论