-- MySQL dump 10.9
--
-- Host: localhost    Database: aceam
-- ------------------------------------------------------
-- Server version	4.1.20

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

--
-- Table structure for table `SEQUENCE`
--

DROP TABLE IF EXISTS `SEQUENCE`;
CREATE TABLE `SEQUENCE` (
  `SEQ_NAME` varchar(50) NOT NULL default '',
  `SEQ_COUNT` decimal(38,0) default NULL,
  PRIMARY KEY  (`SEQ_NAME`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `collection`
--

DROP TABLE IF EXISTS `collection`;
CREATE TABLE `collection` (
  `ID` bigint(20) NOT NULL auto_increment,
  `STORAGE` varchar(255) default NULL,
  `CHECKPERIOD` int(11) default NULL,
  `DIRECTORY` varchar(255) NOT NULL default '',
  `PROXYDATA` tinyint(1) default '0',
  `NAME` varchar(255) NOT NULL default '',
  `AUDITTOKENS` tinyint(1) default '0',
  `LASTSYNC` datetime default NULL,
  `STATE` char(1) default NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `irodssettings`
--

DROP TABLE IF EXISTS `irodssettings`;
CREATE TABLE `irodssettings` (
  `ID` bigint(20) NOT NULL auto_increment,
  `ZONE` varchar(255) NOT NULL default '',
  `SERVER` varchar(255) NOT NULL default '',
  `PASSWORD` varchar(255) NOT NULL default '',
  `PORT` int(11) NOT NULL default '0',
  `USERNAME` varchar(255) NOT NULL default '',
  `COLLECTION_ID` bigint(20) NOT NULL default '0',
  PRIMARY KEY  (`ID`),
  KEY `FK_irodssettings_COLLECTION_ID` (`COLLECTION_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `logevent`
--

DROP TABLE IF EXISTS `logevent`;
CREATE TABLE `logevent` (
  `ID` bigint(20) NOT NULL auto_increment,
  `SESSION` bigint(20) default NULL,
  `PATH` text character set latin1 collate latin1_bin,
  `DESCRIPTION` text,
  `DATE` datetime default NULL,
  `LOGTYPE` int(11) default NULL,
  `COLLECTION_ID` bigint(20) default NULL,
  PRIMARY KEY  (`ID`),
  KEY `logevent_path_idx` (`PATH`(512)),
  KEY `logeven_session_idx` (`SESSION`),
  KEY `logevent_type_idx` (`LOGTYPE`),
  KEY `FK_logevent_COLLECTION_ID` (`COLLECTION_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `monitored_item`
--

DROP TABLE IF EXISTS `monitored_item`;
CREATE TABLE `monitored_item` (
  `ID` bigint(20) NOT NULL auto_increment,
  `DIRECTORY` tinyint(1) NOT NULL default '0',
  `LASTSEEN` datetime default NULL,
  `PATH` text character set latin1 collate latin1_bin,
  `STATE` char(1) NOT NULL default '',
  `PARENTPATH` text character set latin1 collate latin1_bin,
  `TOKEN_ID` bigint(20) default NULL,
  `PARENTCOLLECTION_ID` bigint(20) NOT NULL default '0',
  `STATECHANGE` datetime default NULL,
  PRIMARY KEY  (`ID`),
  KEY `idx_monitored_item_path` (`PATH`(512)),
  KEY `logevent_parentpath_idx` (`PARENTPATH`(512)),
  KEY `idx_monitored_item_state` (`STATE`),
  KEY `FK_monitored_item_PARENTCOLLECTION_ID` (`PARENTCOLLECTION_ID`),
  KEY `FK_monitored_item_TOKEN_ID` (`TOKEN_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `srbsettings`
--

DROP TABLE IF EXISTS `srbsettings`;
CREATE TABLE `srbsettings` (
  `ID` bigint(20) NOT NULL auto_increment,
  `ZONE` varchar(255) NOT NULL default '',
  `SERVER` varchar(255) NOT NULL default '',
  `USERNAME` varchar(255) NOT NULL default '',
  `DOMAIN` varchar(255) NOT NULL default '',
  `PORT` int(11) NOT NULL default '0',
  `PASSWORD` varchar(255) NOT NULL default '',
  `COLLECTION_ID` bigint(20) NOT NULL default '0',
  PRIMARY KEY  (`ID`),
  KEY `FK_srbsettings_COLLECTION_ID` (`COLLECTION_ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `token`
--

DROP TABLE IF EXISTS `token`;
CREATE TABLE `token` (
  `ID` bigint(20) NOT NULL auto_increment,
  `CREATEDATE` datetime default NULL,
  `VALID` tinyint(1) default '0',
  `LASTVALIDATED` datetime default NULL,
  `java_token_response` blob,
  `FILEDIGEST` varchar(255) default NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `userroles`
--

DROP TABLE IF EXISTS `userroles`;
CREATE TABLE `userroles` (
  `ID` bigint(20) NOT NULL auto_increment,
  `USERNAME` varchar(255) default NULL,
  `ROLENAME` varchar(255) default NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Table structure for table `users`
--

DROP TABLE IF EXISTS `users`;
CREATE TABLE `users` (
  `ID` bigint(20) NOT NULL auto_increment,
  `USERNAME` varchar(255) default NULL,
  `PASSWORD` varchar(255) default NULL,
  PRIMARY KEY  (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

