aboutsummaryrefslogtreecommitdiff
path: root/DocumentService/DBSQL
diff options
context:
space:
mode:
authorAlexander Marsalek <amarsalek@iaik.tugraz.at>2014-06-04 18:50:50 +0200
committerAlexander Marsalek <amarsalek@iaik.tugraz.at>2014-06-04 18:56:07 +0200
commitf81b3716ac27094ab1845668cb38a1fe6a2d5f8c (patch)
tree933cd9ae96e6c7c01b78aea37b904b31419b1b0f /DocumentService/DBSQL
parent31c8bad4214bfee45eef0ca98faf3f6f32fe5b23 (diff)
downloadmoa-id-spss-f81b3716ac27094ab1845668cb38a1fe6a2d5f8c.tar.gz
moa-id-spss-f81b3716ac27094ab1845668cb38a1fe6a2d5f8c.tar.bz2
moa-id-spss-f81b3716ac27094ab1845668cb38a1fe6a2d5f8c.zip
added DocumentService
Diffstat (limited to 'DocumentService/DBSQL')
-rw-r--r--DocumentService/DBSQL/mysql-connector-java-5.1.27-bin.jarbin0 -> 872303 bytes
-rw-r--r--DocumentService/DBSQL/tables.sql59
2 files changed, 59 insertions, 0 deletions
diff --git a/DocumentService/DBSQL/mysql-connector-java-5.1.27-bin.jar b/DocumentService/DBSQL/mysql-connector-java-5.1.27-bin.jar
new file mode 100644
index 000000000..a10268c92
--- /dev/null
+++ b/DocumentService/DBSQL/mysql-connector-java-5.1.27-bin.jar
Binary files differ
diff --git a/DocumentService/DBSQL/tables.sql b/DocumentService/DBSQL/tables.sql
new file mode 100644
index 000000000..3fa912357
--- /dev/null
+++ b/DocumentService/DBSQL/tables.sql
@@ -0,0 +1,59 @@
+CREATE DATABASE STORKTRANSFER;
+
+USE STORKTRANSFER;
+
+CREATE TABLE `document` (
+ `DOCID` varchar(255) NOT NULL,
+ `DOCUMENT` longblob,
+ `FILENAME` varchar(255) DEFAULT NULL,
+ `MIMETYPE` longtext,
+ `CREATED` datetime DEFAULT NULL,
+ `UPDATED` datetime DEFAULT NULL,
+ `DELETED` datetime DEFAULT NULL,
+ `RECEIVERCERT` longtext,
+ `ENCKEY` longtext,
+ `ENCIV` longtext,
+ PRIMARY KEY (`DOCID`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+
+CREATE TABLE `request` (
+ `REQUESTID` varchar(255) NOT NULL,
+ `DOCID` varchar(255) DEFAULT NULL,
+ `DESTCOUNTRY` varchar(10) NOT NULL,
+ `SPCOUNTRY` varchar(10) NOT NULL,
+ `SPID` varchar(255) NOT NULL,
+ `XMLREQUEST` longtext,
+ `XMLRESPONSE` longtext,
+ `REQTIMESTAMP` datetime DEFAULT NULL,
+ `RESTIMESTAMP` datetime DEFAULT NULL,
+ PRIMARY KEY (`REQUESTID`),
+ KEY `docid_idx` (`DOCID`),
+ CONSTRAINT `docidindex` FOREIGN KEY (`DOCID`) REFERENCES `document` (`DOCID`) ON DELETE NO ACTION ON UPDATE NO ACTION
+) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+
+CREATE TABLE `spid` (
+ `ID` int(11) NOT NULL AUTO_INCREMENT,
+ `SPID` varchar(45) NOT NULL,
+ `NAME` varchar(100) DEFAULT NULL,
+ `DESC` varchar(500) DEFAULT NULL,
+ PRIMARY KEY (`ID`)
+) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;
+SELECT * FROM STORKTRANSFER.spid;
+
+CREATE TABLE `temp_document` (
+ `DOCID` varchar(255) NOT NULL,
+ `DOCUMENT` longblob,
+ `MIMETYPE` longtext,
+ `CREATED` datetime DEFAULT NULL,
+ `FETCHED` datetime DEFAULT NULL,
+ `DELETED` datetime DEFAULT NULL,
+ `RECEIVERCERT` longtext,
+ `ENCKEY` longtext,
+ `ENCIV` longtext,
+ `SPID` int(11) DEFAULT NULL,
+ PRIMARY KEY (`DOCID`),
+ KEY `SPconstraint_idx` (`SPID`),
+ CONSTRAINT `SPconstraint` FOREIGN KEY (`SPID`) REFERENCES `spid` (`ID`) ON DELETE NO ACTION ON UPDATE NO ACTION
+) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Temp table for SP documents';
+