-- =======================================================================
--   DBMS name:      Informix                                             
--   Version:        9.30 or higher                                       
--   Notes:          Require max pagesize 16k at least                    
--   Created on:     2016-05-16                                           
-- =======================================================================

-- =======================================================================
--   system database                                                      
-- =======================================================================
DROP TABLE CFG_PROPS_2;
DROP TABLE GLOBAL_NLS_FONT_1;
DROP TABLE GLOBAL_NLS_FORMAT_1;
DROP TABLE GLOBAL_NLS_TEXT_1;
DROP TABLE MEMBERS;
DROP TABLE RESOURCE_LOCK;
DROP TABLE TBL_DUAL_JINFONET;
DROP TABLE TBL_IDGENRATOR_JINFONET;
DROP TABLE TBL_LOCK_JINFONET;
DROP TABLE UPDATEDETAILS_1;
CREATE TABLE CFG_PROPS_2(PROP_NAME VARCHAR(128) NOT NULL,PROP_KEY LVARCHAR(512) NOT NULL,PROP_VALUE LVARCHAR(512),IS_LOB SMALLINT NOT NULL,LOB_VAL BYTE, PRIMARY KEY(PROP_NAME,PROP_KEY));
CREATE TABLE GLOBAL_NLS_FONT_1(LOC VARCHAR(10) NOT NULL,ORG_FACE VARCHAR(20) NOT NULL,ORG_SIZE INTEGER NOT NULL,TAR_FACE VARCHAR(20) NOT NULL,TAR_SIZE INTEGER NOT NULL,IS_RELATIVE SMALLINT NOT NULL, PRIMARY KEY(LOC,ORG_FACE,ORG_SIZE));
CREATE TABLE GLOBAL_NLS_FORMAT_1(LOC VARCHAR(10) NOT NULL,KEY_FORMAT LVARCHAR(255) NOT NULL,VALUE_FORMAT LVARCHAR(512) NOT NULL, PRIMARY KEY(LOC,KEY_FORMAT));
CREATE TABLE GLOBAL_NLS_TEXT_1(LOC VARCHAR(10) NOT NULL,NLS_TYPE INTEGER NOT NULL,KEY_TEXT LVARCHAR(255) NOT NULL,VALUE_TEXT LVARCHAR(512) NOT NULL, PRIMARY KEY(LOC,NLS_TYPE,KEY_TEXT));
CREATE TABLE MEMBERS(MEMBER_ID INTEGER NOT NULL,RMI_HOST VARCHAR(32) NOT NULL,RMI_PORT INTEGER NOT NULL, PRIMARY KEY(MEMBER_ID));
CREATE TABLE RESOURCE_LOCK(LOCK_NAME LVARCHAR(512) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE TBL_DUAL_JINFONET(DUAL_COL SMALLINT NOT NULL);
CREATE TABLE TBL_IDGENRATOR_JINFONET(TF_NAME VARCHAR(64) NOT NULL,NEXT_ID INTEGER NOT NULL, PRIMARY KEY(TF_NAME));
CREATE TABLE TBL_LOCK_JINFONET(LOCK_NAME LVARCHAR(255) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE UPDATEDETAILS_1(UPDATE_ITEM VARCHAR(32) NOT NULL,UPDATE_STATE SMALLINT NOT NULL, PRIMARY KEY(UPDATE_ITEM));

-- =======================================================================
--   profile database                                                     
-- =======================================================================
DROP TABLE RESOURCE_LOCK;
DROP TABLE TASKAUDIT;
DROP TABLE TASKCONTEXT_2;
DROP TABLE TBL_DUAL_JINFONET;
DROP TABLE TBL_IDGENRATOR_JINFONET;
DROP TABLE TBL_LOCK_JINFONET;
DROP TABLE UPDATEDETAILS_1;
CREATE TABLE RESOURCE_LOCK(LOCK_NAME LVARCHAR(512) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE TASKAUDIT(ID INTEGER NOT NULL,TASK_ID VARCHAR(128),REPORT_NAME LVARCHAR(256),CATALOG_NAME LVARCHAR(256),CATALOG_NAMES BYTE,USER_NAME VARCHAR(128),TASK_TYPE INTEGER,TASK_STATUS INTEGER,PAGE_NUMBER INTEGER,RUN_TIMES INTEGER,SUBMIT_TIME INT8,START_TIME INT8,COMPLETE_TIME INT8,FAIL_REASON LVARCHAR(256),PARAMETERS BYTE, PRIMARY KEY(ID));
CREATE TABLE TASKCONTEXT_2(ID INTEGER NOT NULL,VS_RPT_NAME LVARCHAR(255),VI_TSK_TYPE INTEGER,VI_TSK_STATUS INTEGER,TS_TSK_SUBMIT DATETIME YEAR TO FRACTION,TS_ENG_START DATETIME YEAR TO FRACTION,TS_ENG_EXITS DATETIME YEAR TO FRACTION,TS_TSK_COMPLETE DATETIME YEAR TO FRACTION,TC_TSK_TOTAL INT8,TC_TSK_WAITED INT8,TC_ENG_TOTAL INT8,TC_ENG_LOAD INT8,TC_ENG_EXPORT INT8,TC_ENG_OTHER INT8,TC_TSK_OTHER INT8,NC_RPT_PAGES INT8,NC_RPT_FORMATS INT8,NC_ENG_CONCURRENT INT8,NC_QUE_LENGTH INT8,TASK_TYPE VARCHAR(16), PRIMARY KEY(ID));
CREATE TABLE TBL_DUAL_JINFONET(DUAL_COL SMALLINT NOT NULL);
CREATE TABLE TBL_IDGENRATOR_JINFONET(TF_NAME VARCHAR(64) NOT NULL,NEXT_ID INTEGER NOT NULL, PRIMARY KEY(TF_NAME));
CREATE TABLE TBL_LOCK_JINFONET(LOCK_NAME LVARCHAR(255) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE UPDATEDETAILS_1(UPDATE_ITEM VARCHAR(32) NOT NULL,UPDATE_STATE SMALLINT NOT NULL, PRIMARY KEY(UPDATE_ITEM));

-- =======================================================================
--   realm database                                                       
-- =======================================================================
DROP TABLE ACLENTRIES_3;
DROP TABLE ACLS_2;
DROP TABLE ACLS_WITH_RESOURCE_1;
DROP TABLE ALIASES_2;
DROP TABLE ALIAS_MAPPING;
DROP TABLE ALIAS_MAPPING_KEY;
DROP TABLE CATALOGVERSION_4;
DROP TABLE CFG_PROPS_2;
DROP TABLE COMPLETEDPUBLISHTABLE_2;
DROP TABLE COMPLETEDRESULTTABLE_3;
DROP TABLE COMPLETEDTABLE_4;
DROP TABLE JR_QRTZ_TRIGGER_LISTENERS;
DROP TABLE JR_QRTZ_SIMPLE_TRIGGERS;
DROP TABLE JR_QRTZ_JOB_LISTENERS;
DROP TABLE JR_QRTZ_CRON_TRIGGERS;
DROP TABLE JR_QRTZ_BLOB_TRIGGERS;
DROP TABLE JR_QRTZ_TRIGGERS;
DROP TABLE JR_QRTZ_JOB_DETAILS;
DROP TABLE DYN_BVELE_NAME_MAPPING_1;
DROP TABLE DYN_BVELE_NAME_1;
DROP TABLE DYNAMIC_CONNECTIONS_MAPPING_2;
DROP TABLE DYNAMIC_CONNECTIONS_2;
DROP TABLE DASHBOARDLISTENERTARGET_1;
DROP TABLE DASHBOARDLISTENER_1;
DROP TABLE CRD_CONN_INFO_1;
DROP TABLE CRDRUNDETAIL_1;
DROP TABLE CRD_INFO_5;
DROP TABLE COMP_CRD_CONN_INFO_1;
DROP TABLE COMPLETED_CRD_INFO_3;
DROP TABLE CUSTOM_FIELD_1;
DROP TABLE CUSTOM_FIELD_VALUE_1;
DROP TABLE DRESULT_3;
DROP TABLE DYNAMICNODE_5;
DROP TABLE DYNAMICRESULT_2;
DROP TABLE DYN_SECURITY_1;
DROP TABLE EXTENDACLENTRIES_3;
DROP TABLE FOLDERS_4;
DROP TABLE GROUPPROFILES_2;
DROP TABLE GROUPS_3;
DROP TABLE GUPROFILES_3;
DROP TABLE HISTORY_PARAMLIST_TABLE_1;
DROP TABLE JR_QRTZ_CALENDARS;
DROP TABLE JR_QRTZ_FIRED_TRIGGERS;
DROP TABLE JR_QRTZ_LOCKS;
DROP TABLE JR_QRTZ_PAUSED_TRIGGER_GRPS;
DROP TABLE JR_QRTZ_SCHEDULER_STATE;
DROP TABLE LCVERSION_2;
DROP TABLE NODES_6;
DROP TABLE ORGANIZATIONS_1;
DROP TABLE REPORTVERSION_4;
DROP TABLE RESOURCEMAP_2;
DROP TABLE RESOURCENLS_1;
DROP TABLE RESOURCENODES_5;
DROP TABLE RESOURCE_LOCK;
DROP TABLE RESULTVERSION_3;
DROP TABLE RESULT_3;
DROP TABLE RGPROFILES_2;
DROP TABLE ROLEPROFILES_3;
DROP TABLE ROLES_4;
DROP TABLE SCHDLASTEXETIME_1;
DROP TABLE STORAGE_MEMBER_1;
DROP TABLE STORAGE_RESOURCE_1;
DROP TABLE TBL_DUAL_JINFONET;
DROP TABLE TBL_IDGENRATOR_JINFONET;
DROP TABLE TBL_LOCK_JINFONET;
DROP TABLE TRIGGERS_1;
DROP TABLE UPDATEDETAILS_1;
DROP TABLE USERPROFILES_4;
DROP TABLE USERS_4;
DROP TABLE VERSIONNODES_3;
CREATE TABLE ACLENTRIES_3(ENTRY_ID INTEGER NOT NULL,ACL_ID INTEGER NOT NULL,PRINCIPAL_TYPE SMALLINT NOT NULL,PRINCIPAL_NAME LVARCHAR(256) NOT NULL,IS_POSITIVE SMALLINT NOT NULL,PERMISSIONS INTEGER NOT NULL, PRIMARY KEY(ENTRY_ID));
CREATE TABLE ACLS_2(ID INTEGER NOT NULL,NAME VARCHAR(64) NOT NULL,CREATE_NAME VARCHAR(32) NOT NULL,CREATE_TIME INT8, PRIMARY KEY(ID));
CREATE TABLE ACLS_WITH_RESOURCE_1(ID INTEGER NOT NULL,RESOURCE_PATH LVARCHAR(256) NOT NULL,VERSION_NUMBER INTEGER NOT NULL,ACL_NAME LVARCHAR(512) NOT NULL,CREATE_NAME VARCHAR(32) NOT NULL,CREATE_TIME INT8, PRIMARY KEY(ID));
CREATE TABLE ALIASES_2(ID INTEGER NOT NULL,PRINCIPAL_NAME LVARCHAR(256) NOT NULL,PRINCIPAL_TYPE SMALLINT NOT NULL,ALIAS_NAME LVARCHAR(256) NOT NULL,PARENT_NAME LVARCHAR(256),MAP_RESOURCE LVARCHAR(256) NOT NULL,HIDDEN SMALLINT NOT NULL, UNIQUE(ID));
CREATE TABLE ALIAS_MAPPING(KEY_ID INTEGER NOT NULL,FIELD_TYPE INTEGER NOT NULL,FIELD_SIGNATURE VARCHAR(32) NOT NULL,FIELD_CATLOG LVARCHAR(256) NOT NULL,FIELD_DATASOURCE LVARCHAR(256) NOT NULL,FIELD_QUERY LVARCHAR(256) NOT NULL,FIELD_DETAILS BYTE NOT NULL, PRIMARY KEY(KEY_ID,FIELD_TYPE,FIELD_SIGNATURE));
CREATE TABLE ALIAS_MAPPING_KEY(ID INTEGER NOT NULL,MAPPING_KEY LVARCHAR(256) NOT NULL, PRIMARY KEY(ID), UNIQUE(MAPPING_KEY));
CREATE TABLE CATALOGVERSION_4(VERSIONNUMBER INTEGER NOT NULL,VERSIONNAME VARCHAR(128),RESOURCEID INTEGER NOT NULL,CREATOR VARCHAR(128),CREATEDTIME INT8 NOT NULL,MODIFIER VARCHAR(128),MODIFIEDTIME INT8 NOT NULL,CATALOGFILE LVARCHAR(512) NOT NULL,ID INT8 NOT NULL,DISKSIZE INT8, UNIQUE(ID));
CREATE TABLE CFG_PROPS_2(PROP_NAME VARCHAR(128) NOT NULL,PROP_KEY LVARCHAR(512) NOT NULL,PROP_VALUE LVARCHAR(512),IS_LOB SMALLINT NOT NULL,LOB_VAL BYTE, PRIMARY KEY(PROP_NAME,PROP_KEY));
CREATE TABLE COMPLETEDPUBLISHTABLE_2(ID INTEGER NOT NULL,RECORDID VARCHAR(40) NOT NULL,SHEETNAME LVARCHAR(256) NOT NULL,DISPLAYNAME LVARCHAR(256),PUB_TYPE VARCHAR(64) NOT NULL);
CREATE TABLE COMPLETEDRESULTTABLE_3(PUBLISHID INTEGER NOT NULL,RECORDID VARCHAR(40) NOT NULL,PUB_TYPE VARCHAR(128) NOT NULL,STATUS INTEGER NOT NULL,DETAIL LVARCHAR(256) NOT NULL);
CREATE TABLE COMPLETEDTABLE_4(ID INTEGER NOT NULL,RECORDID VARCHAR(128),TASKID VARCHAR(128) NOT NULL,TASKCLASS LVARCHAR(256) NOT NULL,CATFILE LVARCHAR(256),RPTFILE LVARCHAR(256),PARAMFILE LVARCHAR(256),RESULTFILE LVARCHAR(1024),ERROR LVARCHAR(256),ENGMSG LVARCHAR(512),SUBMITTER VARCHAR(128),COMPLETEDTIME INT8,FORMATEXISTS INTEGER,FORMATSUCCESSFUL INTEGER,VERSIONID INTEGER,LAUNCHTYPE INTEGER,ISSUCCESSFUL SMALLINT NOT NULL,TASKNAME VARCHAR(128),ISMISSED SMALLINT NOT NULL,SCHEDULETRIGGER VARCHAR(80),CONDITIONSLOGIC VARCHAR(16),REPORTNAMES LVARCHAR(512));
CREATE TABLE COMPLETED_CRD_INFO_3(ID INTEGER NOT NULL,SVERSION INTEGER,CATALOGID INTEGER,CATALOGPATH LVARCHAR(255),DATASOURCE LVARCHAR(255),QUERYTYPE INTEGER,QUERYNAME LVARCHAR(255),LASTMODIFIED INT8,USERNAME LVARCHAR(255),PWD LVARCHAR(255),PARAMFILE LVARCHAR(255),LAZY INTEGER,CATALOGVERSION INTEGER,CATALOGLASTMODIFIED INT8,STARTTIME INT8,COMPLETEDTIME INT8,SUCC INTEGER,BVNAME LVARCHAR(255),ACTIVITYTYPE SMALLINT,MESSAGE LVARCHAR(512), UNIQUE(ID));
CREATE TABLE COMP_CRD_CONN_INFO_1(ID INTEGER,CONNNAME LVARCHAR(256),USERNAME LVARCHAR(256),PWD LVARCHAR(256), FOREIGN KEY (ID) REFERENCES COMPLETED_CRD_INFO_3(ID));
CREATE TABLE CRD_INFO_5(ID INTEGER NOT NULL,SVERSION INTEGER,CATALOGID INTEGER,CATALOGPATH LVARCHAR(255),DATASOURCE LVARCHAR(255),QUERYTYPE INTEGER,QUERYNAME LVARCHAR(255),LASTMODIFIED INT8,USERNAME LVARCHAR(255),PWD LVARCHAR(255),PARAMFILE LVARCHAR(255),LAZY INTEGER,RESULTVERSION INTEGER,CATALOGVERSION INTEGER,CATALOGLASTMODIFIED INT8,TASKID LVARCHAR(255),CONFIGFILE LVARCHAR(255),LOGINUSER LVARCHAR(255),CACHETYPE INTEGER,BVNAME LVARCHAR(255),STATUS SMALLINT,CREATETIME INT8,MAXMEMORY DECIMAL(32),FLAGS INTEGER,LOCATION SMALLINT, UNIQUE(ID));
CREATE TABLE CRDRUNDETAIL_1(ID INTEGER,ACTIVITY SMALLINT,STARTTIME INT8,ENDTIME INT8,SUCC SMALLINT, FOREIGN KEY (ID) REFERENCES CRD_INFO_5(ID));
CREATE TABLE CRD_CONN_INFO_1(ID INTEGER,CONNNAME LVARCHAR(256),USERNAME LVARCHAR(256),PWD LVARCHAR(256), FOREIGN KEY (ID) REFERENCES CRD_INFO_5(ID));
CREATE TABLE DASHBOARDLISTENER_1(CLASSNAME LVARCHAR(512) NOT NULL,DESCRIPTION LVARCHAR(255),ENABLED SMALLINT NOT NULL,CREATETIME INT8, PRIMARY KEY(CLASSNAME));
CREATE TABLE DASHBOARDLISTENERTARGET_1(CLASSNAME LVARCHAR(512),TARGET LVARCHAR(512),APPLYTIME INT8, FOREIGN KEY (CLASSNAME) REFERENCES DASHBOARDLISTENER_1(CLASSNAME));
CREATE TABLE DYNAMIC_CONNECTIONS_2(CONN_ID INTEGER NOT NULL,ORG_NAME LVARCHAR(256),CATALOG LVARCHAR(512) NOT NULL,DATASOURCRE LVARCHAR(256) NOT NULL,CONNECTION_NAME LVARCHAR(256),CONN_PROPERTIES BYTE, PRIMARY KEY(CONN_ID));
CREATE TABLE DYNAMIC_CONNECTIONS_MAPPING_2(CONN_ID INTEGER NOT NULL,PRINCIPAL LVARCHAR(512) NOT NULL,PRINCIPAL_TYPE VARCHAR(64) NOT NULL,DB_USER LVARCHAR(256),DB_PASSWORD LVARCHAR(256), PRIMARY KEY(CONN_ID,PRINCIPAL,PRINCIPAL_TYPE), FOREIGN KEY (CONN_ID) REFERENCES DYNAMIC_CONNECTIONS_2(CONN_ID));
CREATE TABLE DYN_BVELE_NAME_1(ID INTEGER NOT NULL,ORG_NAME LVARCHAR(256),CATALOG LVARCHAR(512) NOT NULL,PRINCIPAL_NAME LVARCHAR(512),PRINCIPAL_TYPE VARCHAR(64) NOT NULL, PRIMARY KEY(ID));
CREATE TABLE DYN_BVELE_NAME_MAPPING_1(ID INTEGER NOT NULL,QUALIFIED_NAME LVARCHAR(512) NOT NULL,DISPLAY_NAME VARCHAR(128) NOT NULL, FOREIGN KEY (ID) REFERENCES DYN_BVELE_NAME_1(ID));
CREATE TABLE JR_QRTZ_JOB_DETAILS(JOB_NAME VARCHAR(200) NOT NULL,JOB_GROUP VARCHAR(200) NOT NULL,DESCRIPTION VARCHAR(250),JOB_CLASS_NAME VARCHAR(250) NOT NULL,IS_DURABLE SMALLINT NOT NULL,IS_VOLATILE SMALLINT NOT NULL,IS_STATEFUL SMALLINT NOT NULL,REQUESTS_RECOVERY SMALLINT NOT NULL,JOB_DATA BYTE, PRIMARY KEY(JOB_NAME,JOB_GROUP));
CREATE TABLE JR_QRTZ_TRIGGERS(TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,JOB_NAME VARCHAR(200) NOT NULL,JOB_GROUP VARCHAR(200) NOT NULL,IS_VOLATILE SMALLINT NOT NULL,DESCRIPTION VARCHAR(250),NEXT_FIRE_TIME INT8 NOT NULL,PREV_FIRE_TIME INT8 NOT NULL,PRIORITY INTEGER NOT NULL,TRIGGER_STATE VARCHAR(16) NOT NULL,TRIGGER_TYPE VARCHAR(8) NOT NULL,START_TIME INT8 NOT NULL,END_TIME INT8,CALENDAR_NAME VARCHAR(200),MISFIRE_INSTR SMALLINT,JOB_DATA BYTE, PRIMARY KEY(TRIGGER_NAME,TRIGGER_GROUP), FOREIGN KEY (JOB_NAME,JOB_GROUP) REFERENCES JR_QRTZ_JOB_DETAILS(JOB_NAME,JOB_GROUP));
CREATE TABLE JR_QRTZ_BLOB_TRIGGERS(TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,BLOB_DATA BYTE, PRIMARY KEY(TRIGGER_NAME,TRIGGER_GROUP), FOREIGN KEY (TRIGGER_NAME,TRIGGER_GROUP) REFERENCES JR_QRTZ_TRIGGERS(TRIGGER_NAME,TRIGGER_GROUP));
CREATE TABLE JR_QRTZ_CRON_TRIGGERS(TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,CRON_EXPRESSION VARCHAR(120) NOT NULL,TIME_ZONE_ID VARCHAR(80), PRIMARY KEY(TRIGGER_NAME,TRIGGER_GROUP), FOREIGN KEY (TRIGGER_NAME,TRIGGER_GROUP) REFERENCES JR_QRTZ_TRIGGERS(TRIGGER_NAME,TRIGGER_GROUP));
CREATE TABLE JR_QRTZ_JOB_LISTENERS(JOB_NAME VARCHAR(200) NOT NULL,JOB_GROUP VARCHAR(200) NOT NULL,JOB_LISTENER VARCHAR(200) NOT NULL, PRIMARY KEY(JOB_NAME,JOB_GROUP,JOB_LISTENER), FOREIGN KEY (JOB_NAME,JOB_GROUP) REFERENCES JR_QRTZ_JOB_DETAILS(JOB_NAME,JOB_GROUP));
CREATE TABLE JR_QRTZ_SIMPLE_TRIGGERS(TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,REPEAT_COUNT INT8 NOT NULL,REPEAT_INTERVAL INT8 NOT NULL,TIMES_TRIGGERED INT8 NOT NULL, PRIMARY KEY(TRIGGER_NAME,TRIGGER_GROUP), FOREIGN KEY (TRIGGER_NAME,TRIGGER_GROUP) REFERENCES JR_QRTZ_TRIGGERS(TRIGGER_NAME,TRIGGER_GROUP));
CREATE TABLE JR_QRTZ_TRIGGER_LISTENERS(TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,TRIGGER_LISTENER VARCHAR(200) NOT NULL, PRIMARY KEY(TRIGGER_NAME,TRIGGER_GROUP,TRIGGER_LISTENER), FOREIGN KEY (TRIGGER_NAME,TRIGGER_GROUP) REFERENCES JR_QRTZ_TRIGGERS(TRIGGER_NAME,TRIGGER_GROUP));
CREATE TABLE CUSTOM_FIELD_1(ID INTEGER NOT NULL,SVERSION INTEGER,ENABLED INTEGER,NAME LVARCHAR(255) NOT NULL,DESCRIPTION LVARCHAR(256), UNIQUE(ID,NAME));
CREATE TABLE CUSTOM_FIELD_VALUE_1(ID INTEGER NOT NULL,SVERSION INTEGER,NODEID INTEGER,NODEREALPATH LVARCHAR(256),FIELDID INTEGER,STRINGVALUE LVARCHAR(256), UNIQUE(ID));
CREATE TABLE DRESULT_3(REPORTSET LVARCHAR(256),VERSIONNUMBER INT8 NOT NULL,REPORT LVARCHAR(256) NOT NULL,REPORTDISPLAYNAME LVARCHAR(256),RESULT LVARCHAR(256) NOT NULL,VIEWEDFORMATS INT8,PLSRESULTFMTS INT8,SECCONSTRAINTFMTS INT8);
CREATE TABLE DYNAMICNODE_5(NAME LVARCHAR(256) NOT NULL,ROOT LVARCHAR(256) NOT NULL,REALPATH LVARCHAR(256) NOT NULL,NODETYPE SMALLINT NOT NULL,ENABLEARCHIVEPOLICY SMALLINT NOT NULL,DELETED SMALLINT NOT NULL,ACLID INTEGER,DESCRIPTION LVARCHAR(256),MAXVERSIONAMOUNT INTEGER,ENABLELINKEDCAT SMALLINT NOT NULL,LINKEDCAT LVARCHAR(256),USEINHERITED SMALLINT NOT NULL,ENABLENLS SMALLINT NOT NULL,STATUS SMALLINT,LINKEDCATID INTEGER);
CREATE TABLE DYNAMICRESULT_2(ID INTEGER NOT NULL,REPORTNAME LVARCHAR(256) NOT NULL,VERSIONNUMBER INTEGER NOT NULL,CREATOR LVARCHAR(256) NOT NULL,CREATEDTIME INT8 NOT NULL,CATALOGVERNUM INTEGER NOT NULL,CATALOGRESNUM INTEGER NOT NULL,REPORTVERNUM INTEGER NOT NULL,REPORTRESNUM INTEGER NOT NULL,PARAMFILE LVARCHAR(256),RESULTFILE LVARCHAR(256) NOT NULL,RESULTFMTS INT8 NOT NULL,LAUNCHTYPE INTEGER NOT NULL,TASKID VARCHAR(128),EXPIRATIONTIME INT8 NOT NULL,EXPIRE SMALLINT NOT NULL,EXPIRATIONMETHOD INTEGER,REPORTAMOUNT INTEGER);
CREATE TABLE DYN_SECURITY_1(ID INTEGER NOT NULL,SVERSION INTEGER,CATALOG_PATH LVARCHAR(255),SECURITY_FILE_NAME LVARCHAR(255),SECURITY_FILE_PATH LVARCHAR(255),TYPE INTEGER, UNIQUE(ID));
CREATE TABLE EXTENDACLENTRIES_3(PRINCIPAL_NAME LVARCHAR(255) NOT NULL,PRINCIPAL_TYPE SMALLINT NOT NULL,PERMISSIONS INTEGER NOT NULL, UNIQUE(PRINCIPAL_NAME,PRINCIPAL_TYPE));
CREATE TABLE FOLDERS_4(ID INTEGER NOT NULL,REALPATH LVARCHAR(256),OWNERNAME LVARCHAR(256),MAXVERSIONAMOUNT INTEGER NOT NULL,ARCHIVENEWVERSION SMALLINT NOT NULL,ENABLEARCHIVEPOLICY SMALLINT NOT NULL,IS_SHARED SMALLINT NOT NULL,ENABLEDYNAMICRESOURCE SMALLINT NOT NULL);
CREATE TABLE GROUPPROFILES_2(GROUP_NAME VARCHAR(65),SUB_GROUP_NAME VARCHAR(65));
CREATE TABLE GROUPS_3(NAME VARCHAR(65) NOT NULL,BUILDIN SMALLINT NOT NULL,DESCRIPTION LVARCHAR(256),GROUP_TYPE INTEGER NOT NULL, PRIMARY KEY(NAME));
CREATE TABLE GUPROFILES_3(GROUP_NAME VARCHAR(65),USER_NAME LVARCHAR(256));
CREATE TABLE HISTORY_PARAMLIST_TABLE_1(ID INTEGER NOT NULL,REALM LVARCHAR(256) NOT NULL,USER11 LVARCHAR(256) NOT NULL,FILE1 BYTE NOT NULL, UNIQUE(ID));
CREATE TABLE JR_QRTZ_CALENDARS(CALENDAR_NAME VARCHAR(200) NOT NULL,CALENDAR BYTE NOT NULL, PRIMARY KEY(CALENDAR_NAME));
CREATE TABLE JR_QRTZ_FIRED_TRIGGERS(ENTRY_ID VARCHAR(95) NOT NULL,TRIGGER_NAME VARCHAR(200) NOT NULL,TRIGGER_GROUP VARCHAR(200) NOT NULL,IS_VOLATILE SMALLINT NOT NULL,INSTANCE_NAME VARCHAR(200) NOT NULL,FIRED_TIME INT8 NOT NULL,PRIORITY INTEGER NOT NULL,STATE VARCHAR(16) NOT NULL,JOB_NAME VARCHAR(200),JOB_GROUP VARCHAR(200),IS_STATEFUL SMALLINT,REQUESTS_RECOVERY SMALLINT, PRIMARY KEY(ENTRY_ID));
CREATE TABLE JR_QRTZ_LOCKS(LOCK_NAME VARCHAR(200) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE JR_QRTZ_PAUSED_TRIGGER_GRPS(TRIGGER_GROUP VARCHAR(200) NOT NULL, PRIMARY KEY(TRIGGER_GROUP));
CREATE TABLE JR_QRTZ_SCHEDULER_STATE(INSTANCE_NAME VARCHAR(200) NOT NULL,LAST_CHECKIN_TIME INT8 NOT NULL,CHECKIN_INTERVAL INT8 NOT NULL, PRIMARY KEY(INSTANCE_NAME));
CREATE TABLE LCVERSION_2(VERSIONNUMBER INTEGER NOT NULL,VERSIONNAME VARCHAR(128),RESOURCEID INTEGER NOT NULL,CREATOR VARCHAR(128),CREATEDTIME INT8 NOT NULL,MODIFIER VARCHAR(128),MODIFIEDTIME INT8 NOT NULL,LCFILE LVARCHAR(512) NOT NULL,ID INT8 NOT NULL,DISKSIZE INT8, UNIQUE(ID));
CREATE TABLE NODES_6(ID INTEGER NOT NULL,NAME LVARCHAR(256) NOT NULL,CREATORNAME LVARCHAR(256) NOT NULL,CREATETIME INT8 NOT NULL,PARENTID INTEGER NOT NULL,NODETYPE SMALLINT NOT NULL,ACLID INTEGER,DESCRIPTION LVARCHAR(256),ENABLELINKEDCAT SMALLINT,LINKEDCAT LVARCHAR(256),USEINHERITED SMALLINT,LINKEDCATID INTEGER,ORGANIZATION VARCHAR(32));
CREATE TABLE ORGANIZATIONS_1(NAME VARCHAR(32) NOT NULL,DESCRIPTION LVARCHAR(256),USERAMOUNT INTEGER, PRIMARY KEY(NAME));
CREATE TABLE REPORTVERSION_4(VERSIONNUMBER INTEGER NOT NULL,VERSIONNAME LVARCHAR(256),RESOURCEID INTEGER NOT NULL,CREATOR LVARCHAR(256),CREATETIME INT8 NOT NULL,MODIFIER LVARCHAR(256),MODIFIEDTIME INT8 NOT NULL,REPORTFILE LVARCHAR(512) NOT NULL,ID INT8 NOT NULL,DISKSIZE INT8, UNIQUE(RESOURCEID,ID));
CREATE TABLE RESOURCEMAP_2(RESOURCEID INTEGER NOT NULL,RESOURCENAME LVARCHAR(512) NOT NULL,RESOURCETYPE SMALLINT NOT NULL);
CREATE TABLE RESOURCENLS_1(LOC VARCHAR(10) NOT NULL,FOLDER_ID INTEGER NOT NULL,KEY_TEXT LVARCHAR(256) NOT NULL,VALUE_TEXT LVARCHAR(512) NOT NULL,ORGANIZATION VARCHAR(32), PRIMARY KEY(LOC,FOLDER_ID,KEY_TEXT));
CREATE TABLE RESOURCENODES_5(ID INTEGER NOT NULL,RESOURCETYPE SMALLINT NOT NULL,REALPATH LVARCHAR(256),MAXVERSIONAMOUNT INTEGER NOT NULL,ARCHIVENEWVERSION SMALLINT NOT NULL,ENABLEARCHIVEPOLICY SMALLINT NOT NULL,PROFILENAME LVARCHAR(256),ENABLENLS SMALLINT NOT NULL,STATUS SMALLINT,RESOURCESUBTYPE SMALLINT);
CREATE TABLE RESOURCE_LOCK(LOCK_NAME LVARCHAR(512) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE RESULTVERSION_3(ID INT8 NOT NULL,VERSIONNUMBER INTEGER NOT NULL,VERSIONNAME VARCHAR(128) NOT NULL,RESOURCEID INTEGER NOT NULL,CREATOR VARCHAR(128),CREATEDTIME INT8 NOT NULL,MODIFIER VARCHAR(128),MODIFIEDTIME INT8 NOT NULL,CATALOGVERNUM INTEGER NOT NULL,CATALOGRESNUM INTEGER NOT NULL,REPORTVERNUM INTEGER NOT NULL,REPORTRESNUM INTEGER NOT NULL,PARAMFILE VARCHAR(128),RESULTFILE VARCHAR(128) NOT NULL,RESULTFMTS INT8 NOT NULL,LAUNCHTYPE INTEGER NOT NULL,TASKID VARCHAR(128),EXPIRATIONTIME INT8 NOT NULL,EXPIRE SMALLINT NOT NULL,EXPIREATIONMETHOD INTEGER,SPECIFIEDFOLDER VARCHAR(128),REPORTAMOUNT INTEGER,DISKSIZE INT8, UNIQUE(ID,RESOURCEID));
CREATE TABLE RESULT_3(RESOURCEID INT8 NOT NULL,VERSIONNUMBER INT8 NOT NULL,REPORT LVARCHAR(256) NOT NULL,REPORTDISPLAYNAME LVARCHAR(256),RESULT LVARCHAR(256) NOT NULL,VIEWEDFORMATS INT8,PLSRESULTFMTS INT8,SECCONSTRAINTFMTS INT8);
CREATE TABLE RGPROFILES_2(ROLE_NAME VARCHAR(65),GROUP_NAME VARCHAR(65));
CREATE TABLE ROLEPROFILES_3(ROLE_NAME VARCHAR(65),SUB_ROLE_NAME VARCHAR(65));
CREATE TABLE ROLES_4(NAME VARCHAR(65) NOT NULL,BUILDIN SMALLINT NOT NULL,DESCRIPTION LVARCHAR(256),ROLE_TYPE INTEGER NOT NULL, PRIMARY KEY(NAME));
CREATE TABLE SCHDLASTEXETIME_1(TASKID VARCHAR(40) NOT NULL,LASTEXETIME INT8 NOT NULL);
CREATE TABLE STORAGE_MEMBER_1(FILEID INTEGER NOT NULL,UNITINDEX INTEGER NOT NULL,BITS INT8 NOT NULL, UNIQUE(FILEID,UNITINDEX));
CREATE TABLE STORAGE_RESOURCE_1(ID INTEGER NOT NULL,PATH LVARCHAR(255) NOT NULL,ISDIRECTORY SMALLINT NOT NULL,LAST_MODIFIED INT8, PRIMARY KEY(ID), UNIQUE(PATH));
CREATE TABLE TBL_DUAL_JINFONET(DUAL_COL SMALLINT NOT NULL);
CREATE TABLE TBL_IDGENRATOR_JINFONET(TF_NAME VARCHAR(64) NOT NULL,NEXT_ID INTEGER NOT NULL, PRIMARY KEY(TF_NAME));
CREATE TABLE TBL_LOCK_JINFONET(LOCK_NAME LVARCHAR(255) NOT NULL, PRIMARY KEY(LOCK_NAME));
CREATE TABLE TRIGGERS_1(TRIGGER_NAME VARCHAR(80) NOT NULL,DESCRIPTION LVARCHAR(255),TRIGGER_TYPE SMALLINT NOT NULL,TRIGGER_STATE SMALLINT NOT NULL,PREV_FIRE_TIME INT8,NEXT_FIRE_TIME INT8, PRIMARY KEY(TRIGGER_NAME));
CREATE TABLE UPDATEDETAILS_1(UPDATE_ITEM VARCHAR(32) NOT NULL,UPDATE_STATE SMALLINT NOT NULL, PRIMARY KEY(UPDATE_ITEM));
CREATE TABLE USERPROFILES_4(USER_NAME LVARCHAR(256),ROLE_NAME VARCHAR(65));
CREATE TABLE USERS_4(NAME LVARCHAR(255) NOT NULL,FULL_NAME LVARCHAR(256),DESCRIPTION LVARCHAR(256),EMAIL LVARCHAR(256),CREATE_TIME INT8 NOT NULL,USER_PSWD LVARCHAR(512),BUILDIN SMALLINT NOT NULL,ENABLE SMALLINT NOT NULL,MIN_PS_LENGTH INTEGER,LAST_MODIFY_TIME INT8,NEVER_EXPIRE SMALLINT NOT NULL,EXPIRE_TIME INTEGER,ACCOUNT_DISABLE SMALLINT NOT NULL,ACCESS_EVENT_SUC SMALLINT NOT NULL,ACCESS_EVENT_FAIL SMALLINT NOT NULL,MANAGEMENT_EVENT_SUC SMALLINT NOT NULL,MANAGEMENT_EVENT_FAIL SMALLINT NOT NULL,NO_AUDIT SMALLINT NOT NULL,AUTH_TYPE INTEGER NOT NULL,LDAP_TYPE INTEGER, PRIMARY KEY(NAME));
CREATE TABLE VERSIONNODES_3(ID INTEGER NOT NULL,RESOURCEID INTEGER NOT NULL,VERSIONNUMBER INTEGER NOT NULL,EXPIRATIONTIME INT8 NOT NULL,AUTHOR LVARCHAR(256),AUTHOREMAIL LVARCHAR(256),BUILDINDESC LVARCHAR(256));
