create table BPEL_ACTIVITY_INST (DBID_ int8 not null, CLASS_ varchar(255) not null, dbversion int8 not null, ACT_INST_UUID_ varchar(3999), ACT_DEF_UUID_ varchar(3999), PROCESS_UUID_ varchar(3999), INST_UUID_ varchar(3999), STARTED_DATE_ timestamp, ENDED_DATE_ timestamp, ACTIVITY_STATE_ varchar(255), LAST_EXCEPTION_ int8, CHILD_ACT_INST_ID_ int8, OPERATION_ varchar(255), VARIABLE_ varchar(255), MESSAGE_EXCHANGE_ varchar(255), FH_INST_ int8, TH_INST_ int8, CH_INST_ int8, START_VALUE_ int4, STOP_VALUE_ int4, COMPLETION_CONDITION_VALUE_ int4, CHILD_WAIT_ACT_ int8, PARENT_ACT_INST_ID_ int8, INDEX_ int4, PARENT_SCOPE_ID_ int8, primary key (DBID_));
create table BPEL_BASE_ACTIVITY_DEF (DBID_ int8 not null, CLASS_ varchar(255) not null, dbversion int8 not null, ACT_DEF_UUID_ varchar(3999), PROCESS_DEF_UUID_ varchar(3999), NAME_ varchar(255), SUPPR_JN_FL_ bool, TGT_JN_CDT_EXP_LG_ varchar(255), TGT_JN_CDT_BLN_LG_ varchar(255), CHILD_ACT_DEF_ID_ int8, FAULT_NAME_NS_URI_ varchar(255), FAULT_NAME_LOCAL_ varchar(255), FAULT_MESSAGE_TYPE_NS_URI_ varchar(255), FAULT_MESSAGE_TYPE_LOCAL_ varchar(255), FAULT_ELEMENT_NS_URI_ varchar(255), FAULT_ELEMENT_LOCAL_ varchar(255), faultVariable varchar(255), EX_ON_STA_FAULT_ bool, TERMINATION_HANDLER_ int8, COMPENSATION_HANDLER_ int8, NAMESPACE_ varchar(255), EXPR_LANG_ varchar(255), QUERY_LANG_ varchar(255), DPLY_DATE_ timestamp, UNDPLY_DATE timestamp, STATE_ varchar(255), TARGET_ varchar(255), IVK_PRTLNK_ varchar(255), IVK_IN_VAR_ varchar(255), IVK_OUT_VAR_ varchar(255), IVK_OPERATION_ varchar(255), IVK_PRT_PT_NS_URI_ varchar(255), IVK_PRT_PT_LOCAL_ varchar(255), PT_NS_URI_ varchar(255), PT_LOCAL_ varchar(255), FAULT_VARIABLE_ varchar(255), WHL_EXP_LANG_ varchar(255), WHL_BOOL_EXP_ varchar(255), RPU_EXP_LANG_ varchar(255), RPU_BOOL_EXP_ varchar(255), REC_CRT_INST_ bool, REC_VAR_ varchar(255), REC_PARTN_LNK_ varchar(255), REC_OPERATION_ varchar(255), REC_MSG_EXCHNG_ varchar(255), REC_PRT_PT_NS_URI_ varchar(255), REC_PRT_PT_LOCAL_ varchar(255), REP_VAR_ varchar(255), REP_PARTN_LNK_ varchar(255), REP_OPERATION_ varchar(255), REP_MSG_EXCHNG_ varchar(255), REP_PRT_PT_NS_URI_ varchar(255), REP_PRT_PT_LOCAL_ varchar(255), REP_FLT_NM_NS_URI_ varchar(255), REP_FLT_NM_LOCAL_ varchar(255), ASSIGN_VLDT_ bool, FOR_EXPR_LANG_ varchar(255), FOR_DUR_LANG_ varchar(255), UNTIL_EXPR_LANG_ varchar(255), UNTIL_DEAD_LANG_ varchar(255), IF_EXPR_LANG_ varchar(255), IF_EXPR_ varchar(255), ELSE_ACT_DEF_ID_ int8, ELSE_ACT_UUID_ varchar(3999), PK_DF_CR_INST_ bool, FRCH_C_N_EXPR_ varchar(255), FRCH_PARLLL_EXPR_ bool, FRCH_FINL_EXPR_ varchar(255), FRCH_FINL_EXPR_LG_ varchar(255), FRCH_STRT_EXPR_ varchar(255), FRCH_STRT_EXPR_LG_ varchar(255), FRCH_CD_EXPR_ varchar(255), FRCH_CD_EXPR_LG_ varchar(255), FRCH_CD_SUCC_ bool, PARENT_ACT_DEF_ID_ int8, INDEX_ int4, SCOPE_ID_ int8, primary key (DBID_));
create table BPEL_FAULT_ (DBID_ int8 not null, CLASS_ varchar(255) not null, FAULT_NS_URI_ varchar(255), FAULT_LOCAL_ varchar(255), ELT_ text, primary key (DBID_));
create table BPEL_FAULT_MSG_PART (PENDING_ID_ int8 not null, ELT_ text, PART_NAME_ varchar(255) not null, primary key (PENDING_ID_, PART_NAME_));
create table COPY_FULL_IMPL (DBID_ int8 not null, KEEP_SRC_ELT_NAME bool, COPY_LST_ID_ int8, INDEX_ int4, primary key (DBID_));
create table CORR_DEF_ (DBID_ int8 not null, SETVALUE_ varchar(255), INITIATE_ varchar(255), ON_MSG_CORR_ID_ int8, INDEX_ int4, ON_EVT_CORR_ID_ int8, IVK_CR_DEF_ID_ int8, REC_CR_DEF_ID_ int8, RP_CR_DEF_ID_ int8, primary key (DBID_));
create table CS_INIT_FULL_IMPL (DBID_ int8 not null, ACT_INST_UUID_ varchar(3999), DATE_ timestamp, NAME_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table ELSEIF_DEF_ (DBID_ int8 not null, ELSEIF_EXPR_ varchar(255), ELSEIF_EXPR_LANG_ varchar(255), ELSEIF_ACT_DEF_ID_ int8, ELSEIF_ACT_UUID_ varchar(3999), IF_ELSEIF_LST_ID_ int8, INDEX_ int4, primary key (DBID_));
create table FRM_PRT_DEF_ (DBID_ int8 not null, FP_PART_ varchar(255), FP_TO_VAR_ varchar(255), ON_MSG_FRM_PRT_ID_ int8, INDEX_ int4, ON_EVT_FRM_PRT_ID_ int8, IVK_FR_PT_ID_ int8, REC_FR_PT_ID_ int8, primary key (DBID_));
create table FROM_TO_FULL (DBID_ int8 not null, CLASS_ varchar(255) not null, FT_VARIANT_ varchar(255), FT_EXP_LANG_ varchar(255), FT_VARIABLE_ varchar(255), FT_PART_ varchar(255), FT_PARTNER_LINK_ varchar(255), FT_ENDPOINT_REF_ varchar(255), FT_PROP_NS_URI_ varchar(255), FT_PROP_LOCAL_ varchar(255), FT_EXPRESSION_ varchar(255), FT_QUERY_ varchar(255), FT_QUERY_LANG_ varchar(255), LITRL_VALUE_ varchar(3999), FROM_LST_ID_ int8, INDEX_ int4, TO_LST_ID_ int8, primary key (DBID_));
create table NOVA_CS_INST_PROP (CS_ID_ int8 not null, VALUE_ text, QNAME_NS_ varchar(255) not null, QNAME_LOCAL_ varchar(255) not null, primary key (CS_ID_, QNAME_NS_, QNAME_LOCAL_));
create table NOVA_NAMESPACE (DBID_ int8 not null, URI_ varchar(255), PREFIX_ varchar(255), primary key (DBID_));
create table NOVA_VAR_MSG_PART2 (VAR_ID_ int8 not null, ELT_ text, PART_NAME_ varchar(255) not null, primary key (VAR_ID_, PART_NAME_));
create table ON_ALRM_DEF_ (DBID_ int8 not null, ON_ALRM_ACT_DEF_ID_ int8, ON_ALRM_ACT_UUID_ varchar(3999), FOR_EXPR_LANG_ varchar(255), FOR_DUR_LANG_ varchar(255), UNTIL_EXPR_LANG_ varchar(255), UNTIL_DEAD_LANG_ varchar(255), REPETE_EXPR_LANG_ varchar(255), REPEAT_DEAD_LANG_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, PK_DF_ON_AL_ID_ int8, primary key (DBID_));
create table ON_EVT_DEF_ (DBID_ int8 not null, PICK_VAR_ varchar(255), PICK_PART_LNK_ varchar(255), PICK_OPTN_ varchar(255), PICK_MSG_EXCHG_ varchar(255), PICK_PT_TP_NS_URI_ varchar(255), PICK_PT_TP_LOCAL_ varchar(255), ON_EVT_ACT_DEF_ID_ int8, ON_EVT_ACT_UUID_ varchar(3999), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table ON_MSG_DEF_ (DBID_ int8 not null, PICK_VAR_ varchar(255), PICK_PART_LNK_ varchar(255), PICK_OPTN_ varchar(255), PICK_MSG_EXCHG_ varchar(255), PICK_PT_TP_NS_URI_ varchar(255), PICK_PT_TP_LOCAL_ varchar(255), ON_MSG_ACT_DEF_ID_ int8, ON_MSG_ACT_UUID_ varchar(3999), PK_DF_ON_MSG_ID_ int8, INDEX_ int4, primary key (DBID_));
create table PART_LNK_DEF_ (DBID_ int8 not null, NAME_ varchar(255), MY_ROLE_ varchar(255), PARTNER_ROLE_ varchar(255), INIT_PRTN_ROLE_ bool, PRT_LNK_NS_URI_ varchar(255), PRT_LNK_LOCAL_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table PLNK_UPDATE_FULL_IMPL (DBID_ int8 not null, ACT_INST_UUID_ varchar(3999), DATE_ timestamp, NAME_ varchar(255), P_END_REF text, PLNK_UPD_TYPE_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table PROCESS_INST_STATE_UPDATE_ (DBID_ int8 not null, DATE_ timestamp, STATE_ varchar(255), PROCESS_INST_ID_ int8, INDEX_ int4, primary key (DBID_));
create table SCOPE_STATE_UPDATE_ (DBID_ int8 not null, ACT_INST_UUID_ varchar(3999), DATE_ timestamp, STATE_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table SRC_FULL_IMPL (DBID_ int8 not null, LNK_NAME varchar(255), TR_CND_EXP_LG varchar(255), TR_CND_BOL_EXP varchar(255), SRC_LST_ID_ int8, INDEX_ int4, primary key (DBID_));
create table TGT_FULL_IMPL (DBID_ int8 not null, LNK_NAME varchar(255), TRGT_LST_ID_ int8, INDEX_ int4, primary key (DBID_));
create table TO_PRT_DEF_ (DBID_ int8 not null, TP_PART_ varchar(255), TP_FRM_VAR_ varchar(255), IVK_TO_PT_ID_ int8, INDEX_ int4, RP_TO_PT_ID_ int8, primary key (DBID_));
create table TR_COND_UPD_ (DBID_ int8 not null, STATUS_ bool, NAME_ varchar(255), DATE_ timestamp, FLOW_ID_ int8, INDEX_ int4, primary key (DBID_));
create table VAR_DEF_ (DBID_ int8 not null, MSGTYPE_NS_URI_ varchar(255), MSGTYPE_LOCAL_ varchar(255), TYPE_NS_URI_ varchar(255), TYPE_LOCAL_ varchar(255), ELT_NS_URI_ varchar(255), ELT_LOCAL_ varchar(255), NAME_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table VAR_DEF_CS_ (DBID_ int8 not null, NAME_ varchar(255), SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table VAR_UPDATE_FULL_IMPL (DBID_ int8 not null, ACT_INST_UUID_ varchar(3999), DATE_ timestamp, NAME_ varchar(255), XML_VALUE_ text, SCOPE_ID_ int8, INDEX_ int4, primary key (DBID_));
create table WAITING_FULL_IMPL (DBID_ int8 not null, EXPECTED_STARTED_DATE_ timestamp, PICK_ID_ int8, INDEX_ int4, primary key (DBID_));
create table linkList (FLOW_LINKS_ID_ int8 not null, FLOW_LINKS_ varchar(255), INDEX_ int4 not null, primary key (FLOW_LINKS_ID_, INDEX_));
create table messageExchanges (SCOPE_ID_ int8 not null, elt varchar(255), INDEX_ int4 not null, primary key (SCOPE_ID_, INDEX_));
create table properties (CORR_ST_DEF_ID_ int8 not null, PROP_NS_URI_ varchar(255), PROP_LOCAL_ varchar(255), INDEX_ int4 not null, primary key (CORR_ST_DEF_ID_, INDEX_));
create index ACT_INST_EXCEPTION_IDX on BPEL_ACTIVITY_INST (LAST_EXCEPTION_);
create index ACT_INST_PARENT_IDK on BPEL_ACTIVITY_INST (PARENT_ACT_INST_ID_);
create index SCOPE_INST_EVT_IDX on BPEL_ACTIVITY_INST (PARENT_SCOPE_ID_);
create index ACT_INST_CHILD_IDX on BPEL_ACTIVITY_INST (CHILD_ACT_INST_ID_);
create index ACT_INST_FH_IDX on BPEL_ACTIVITY_INST (FH_INST_);
create index ACT_INST_CH_IDX on BPEL_ACTIVITY_INST (CH_INST_);
create index ACT_INST_WAIT_IDX on BPEL_ACTIVITY_INST (CHILD_WAIT_ACT_);
create index ACT_INST_TH_IDX on BPEL_ACTIVITY_INST (TH_INST_);
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_PARENT_FK foreign key (PARENT_ACT_INST_ID_) references BPEL_ACTIVITY_INST;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_CH_FK foreign key (CH_INST_) references BPEL_ACTIVITY_INST;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_TH_FK foreign key (TH_INST_) references BPEL_ACTIVITY_INST;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_FH_FK foreign key (FH_INST_) references BPEL_ACTIVITY_INST;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_EXCEPTION_FK foreign key (LAST_EXCEPTION_) references BPEL_FAULT_;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_WAIT_FK foreign key (CHILD_WAIT_ACT_) references WAITING_FULL_IMPL;
alter table BPEL_ACTIVITY_INST add constraint ACT_INST_CHILD_FK foreign key (CHILD_ACT_INST_ID_) references BPEL_ACTIVITY_INST;
alter table BPEL_ACTIVITY_INST add constraint SCOPE_INST_EVT_FK foreign key (PARENT_SCOPE_ID_) references BPEL_ACTIVITY_INST;
create index SCOPE_DEF_FAULT_HANDLERS_IDX on BPEL_BASE_ACTIVITY_DEF (SCOPE_ID_);
alter table BPEL_BASE_ACTIVITY_DEF add constraint FK90444D19F1C5FAB0 foreign key (PARENT_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table BPEL_BASE_ACTIVITY_DEF add constraint FK90444D1982112BDD foreign key (CHILD_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table BPEL_BASE_ACTIVITY_DEF add constraint FK90444D19614874B5 foreign key (TERMINATION_HANDLER_) references BPEL_BASE_ACTIVITY_DEF;
alter table BPEL_BASE_ACTIVITY_DEF add constraint FK90444D19DE3B31AF foreign key (COMPENSATION_HANDLER_) references BPEL_BASE_ACTIVITY_DEF;
alter table BPEL_BASE_ACTIVITY_DEF add constraint FK90444D19D4D0807A foreign key (ELSE_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table BPEL_BASE_ACTIVITY_DEF add constraint SCOPE_DEF_FAULT_HANDLERS_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index BPEL_FAULT_MSG_PART_IDX on BPEL_FAULT_MSG_PART (PENDING_ID_);
alter table BPEL_FAULT_MSG_PART add constraint BPEL_FAULT_MSG_PART_FK foreign key (PENDING_ID_) references BPEL_FAULT_;
create index COPY_LST_IDX on COPY_FULL_IMPL (COPY_LST_ID_);
alter table COPY_FULL_IMPL add constraint COPY_LST_FK foreign key (COPY_LST_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index RP_CR_DEF_LST_IDX on CORR_DEF_ (RP_CR_DEF_ID_);
create index IVK_CR_DEF_LST_IDX on CORR_DEF_ (IVK_CR_DEF_ID_);
create index ON_MSG_CORR_IDX on CORR_DEF_ (ON_MSG_CORR_ID_);
create index REC_CR_DEF_LST_IDX on CORR_DEF_ (REC_CR_DEF_ID_);
create index ON_EVT_CORR_IDX on CORR_DEF_ (ON_EVT_CORR_ID_);
alter table CORR_DEF_ add constraint REC_CR_DEF_LST_FK foreign key (REC_CR_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table CORR_DEF_ add constraint IVK_CR_DEF_LST_FK foreign key (IVK_CR_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table CORR_DEF_ add constraint RP_CR_DEF_LST_FK foreign key (RP_CR_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table CORR_DEF_ add constraint ON_EVT_CORR_FK foreign key (ON_EVT_CORR_ID_) references ON_EVT_DEF_;
alter table CORR_DEF_ add constraint ON_MSG_CORR_FK foreign key (ON_MSG_CORR_ID_) references ON_MSG_DEF_;
create index SCOPE_INST_CS_IDX on CS_INIT_FULL_IMPL (SCOPE_ID_);
alter table CS_INIT_FULL_IMPL add constraint SCOPE_INST_CS_FK foreign key (SCOPE_ID_) references BPEL_ACTIVITY_INST;
create index IF_ELSEIF_LST_IDX on ELSEIF_DEF_ (IF_ELSEIF_LST_ID_);
alter table ELSEIF_DEF_ add constraint IF_ELSEIF_LST_FK foreign key (IF_ELSEIF_LST_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table ELSEIF_DEF_ add constraint FK4BC7A7A366DBBFD7 foreign key (ELSEIF_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index IVK_FR_PT_LST_IDX on FRM_PRT_DEF_ (IVK_FR_PT_ID_);
create index ON_MSG_FRM_PRT_IDX on FRM_PRT_DEF_ (ON_MSG_FRM_PRT_ID_);
create index ON_EVT_FRM_PRT_IDX on FRM_PRT_DEF_ (ON_EVT_FRM_PRT_ID_);
create index REC_FR_PT_LST_IDX on FRM_PRT_DEF_ (REC_FR_PT_ID_);
alter table FRM_PRT_DEF_ add constraint REC_FR_PT_LST_FK foreign key (REC_FR_PT_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table FRM_PRT_DEF_ add constraint IVK_FR_PT_LST_FK foreign key (IVK_FR_PT_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table FRM_PRT_DEF_ add constraint ON_MSG_FRM_PRT_FK foreign key (ON_MSG_FRM_PRT_ID_) references ON_MSG_DEF_;
alter table FRM_PRT_DEF_ add constraint ON_EVT_FRM_PRT_FK foreign key (ON_EVT_FRM_PRT_ID_) references ON_EVT_DEF_;
create index TO_LST_IDX on FROM_TO_FULL (TO_LST_ID_);
create index FROM_LST_IDX on FROM_TO_FULL (FROM_LST_ID_);
alter table FROM_TO_FULL add constraint FROM_LST_FK foreign key (FROM_LST_ID_) references COPY_FULL_IMPL;
alter table FROM_TO_FULL add constraint TO_LST_FK foreign key (TO_LST_ID_) references COPY_FULL_IMPL;
create index CS_INST_PROP_IDX on NOVA_CS_INST_PROP (CS_ID_);
alter table NOVA_CS_INST_PROP add constraint CS_INST_PROP_FK foreign key (CS_ID_) references CS_INIT_FULL_IMPL;
create index VAR_UPD_MSG_PART_IDX on NOVA_VAR_MSG_PART2 (VAR_ID_);
alter table NOVA_VAR_MSG_PART2 add constraint VAR_UPD_MSG_PART_FK foreign key (VAR_ID_) references VAR_UPDATE_FULL_IMPL;
create index SCOPE_DEF_ALARMS_IDX on ON_ALRM_DEF_ (SCOPE_ID_);
create index PK_DF_ON_AL_IDX on ON_ALRM_DEF_ (PK_DF_ON_AL_ID_);
alter table ON_ALRM_DEF_ add constraint PK_DF_ON_AL_FK foreign key (PK_DF_ON_AL_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table ON_ALRM_DEF_ add constraint FK5B79CBB3735C61C7 foreign key (ON_ALRM_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table ON_ALRM_DEF_ add constraint SCOPE_DEF_ALARMS_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_DEF_EVTS_IDX on ON_EVT_DEF_ (SCOPE_ID_);
alter table ON_EVT_DEF_ add constraint FKC013947699EA93C4 foreign key (ON_EVT_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table ON_EVT_DEF_ add constraint SCOPE_DEF_EVTS_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index PK_DF_ON_MSG_IDX on ON_MSG_DEF_ (PK_DF_ON_MSG_ID_);
alter table ON_MSG_DEF_ add constraint PK_DF_ON_MSG_FK foreign key (PK_DF_ON_MSG_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table ON_MSG_DEF_ add constraint FK4A3B4998A6853462 foreign key (ON_MSG_ACT_DEF_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_DEF_PL_IDX on PART_LNK_DEF_ (SCOPE_ID_);
alter table PART_LNK_DEF_ add constraint SCOPE_DEF_PL_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_INST_PLNK_IDX on PLNK_UPDATE_FULL_IMPL (SCOPE_ID_);
alter table PLNK_UPDATE_FULL_IMPL add constraint SCOPE_INST_PLNK_FK foreign key (SCOPE_ID_) references BPEL_ACTIVITY_INST;
create index PROCESS_INST_STATE_IDX on PROCESS_INST_STATE_UPDATE_ (PROCESS_INST_ID_);
alter table PROCESS_INST_STATE_UPDATE_ add constraint PROCESS_INST_STATE_FK foreign key (PROCESS_INST_ID_) references BPEL_ACTIVITY_INST;
create index SCOPE_INST_STATE_IDX on SCOPE_STATE_UPDATE_ (SCOPE_ID_);
alter table SCOPE_STATE_UPDATE_ add constraint SCOPE_INST_STATE_FK foreign key (SCOPE_ID_) references BPEL_ACTIVITY_INST;
create index SRC_LST_IDX on SRC_FULL_IMPL (SRC_LST_ID_);
alter table SRC_FULL_IMPL add constraint SRC_LST_FK foreign key (SRC_LST_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index TRGT_LST_IDX on TGT_FULL_IMPL (TRGT_LST_ID_);
alter table TGT_FULL_IMPL add constraint TRGT_LST_FK foreign key (TRGT_LST_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index IVK_TO_PT_LST_IDX on TO_PRT_DEF_ (IVK_TO_PT_ID_);
create index RP_TO_PT_LST_IDX on TO_PRT_DEF_ (RP_TO_PT_ID_);
alter table TO_PRT_DEF_ add constraint RP_TO_PT_LST_FK foreign key (RP_TO_PT_ID_) references BPEL_BASE_ACTIVITY_DEF;
alter table TO_PRT_DEF_ add constraint IVK_TO_PT_LST_FK foreign key (IVK_TO_PT_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index FLOW_INST_TR_COND_IDX on TR_COND_UPD_ (FLOW_ID_);
alter table TR_COND_UPD_ add constraint FLOW_INST_TR_COND_FK foreign key (FLOW_ID_) references BPEL_ACTIVITY_INST;
create index SCOPE_DEF_VAR_IDX on VAR_DEF_ (SCOPE_ID_);
alter table VAR_DEF_ add constraint SCOPE_DEF_VAR_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_DEF_CS_IDX on VAR_DEF_CS_ (SCOPE_ID_);
alter table VAR_DEF_CS_ add constraint SCOPE_DEF_CS_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_INST_VAR_IDX on VAR_UPDATE_FULL_IMPL (SCOPE_ID_);
alter table VAR_UPDATE_FULL_IMPL add constraint SCOPE_INST_VAR_FK foreign key (SCOPE_ID_) references BPEL_ACTIVITY_INST;
create index PICK_WAIT_IDX on WAITING_FULL_IMPL (PICK_ID_);
alter table WAITING_FULL_IMPL add constraint PICK_WAIT_FK foreign key (PICK_ID_) references BPEL_ACTIVITY_INST;
create index FLOW_LINKS_IDX on linkList (FLOW_LINKS_ID_);
alter table linkList add constraint FLOW_LINKS_FK foreign key (FLOW_LINKS_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index SCOPE_DEF_M_E_IDX on messageExchanges (SCOPE_ID_);
alter table messageExchanges add constraint SCOPE_DEF_M_E_FK foreign key (SCOPE_ID_) references BPEL_BASE_ACTIVITY_DEF;
create index CORR_ST_DEF_IDX on properties (CORR_ST_DEF_ID_);
alter table properties add constraint CORR_ST_DEF_FK foreign key (CORR_ST_DEF_ID_) references VAR_DEF_CS_;
create sequence hibernate_sequence;
