|
Lines 1457-1486
CREATE TABLE `search_marc_to_field` (
Link Here
|
| 1457 |
FOREIGN KEY(search_field_id) REFERENCES search_field(id) ON DELETE CASCADE ON UPDATE CASCADE |
1457 |
FOREIGN KEY(search_field_id) REFERENCES search_field(id) ON DELETE CASCADE ON UPDATE CASCADE |
| 1458 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
1458 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1459 |
|
1459 |
|
| 1460 |
-- |
|
|
| 1461 |
-- Table structure for table `serial` |
| 1462 |
-- |
| 1463 |
|
| 1464 |
DROP TABLE IF EXISTS `serial`; |
| 1465 |
CREATE TABLE `serial` ( -- issues related to subscriptions |
| 1466 |
`serialid` int(11) NOT NULL auto_increment, -- unique key for the issue |
| 1467 |
`biblionumber` varchar(100) NOT NULL default '', -- foreign key for the biblio.biblionumber that this issue is attached to |
| 1468 |
`subscriptionid` varchar(100) NOT NULL default '', -- foreign key to the subscription.subscriptionid that this issue is part of |
| 1469 |
`serialseq` varchar(100) NOT NULL default '', -- issue information (volume, number, etc) |
| 1470 |
`serialseq_x` varchar( 100 ) NULL DEFAULT NULL, -- first part of issue information |
| 1471 |
`serialseq_y` varchar( 100 ) NULL DEFAULT NULL, -- second part of issue information |
| 1472 |
`serialseq_z` varchar( 100 ) NULL DEFAULT NULL, -- third part of issue information |
| 1473 |
`status` tinyint(4) NOT NULL default 0, -- status code for this issue (see manual for full descriptions) |
| 1474 |
`planneddate` date default NULL, -- date expected |
| 1475 |
`notes` MEDIUMTEXT, -- notes |
| 1476 |
`publisheddate` date default NULL, -- date published |
| 1477 |
publisheddatetext varchar(100) default NULL, -- date published (descriptive) |
| 1478 |
`claimdate` date default NULL, -- date claimed |
| 1479 |
claims_count int(11) default 0, -- number of claims made related to this issue |
| 1480 |
`routingnotes` MEDIUMTEXT, -- notes from the routing list |
| 1481 |
PRIMARY KEY (`serialid`) |
| 1482 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1483 |
|
| 1484 |
-- |
1460 |
-- |
| 1485 |
-- Table structure for table `sessions` |
1461 |
-- Table structure for table `sessions` |
| 1486 |
-- |
1462 |
-- |
|
Lines 1993-1999
CREATE TABLE subscription_numberpatterns (
Link Here
|
| 1993 |
|
1969 |
|
| 1994 |
DROP TABLE IF EXISTS `subscription`; |
1970 |
DROP TABLE IF EXISTS `subscription`; |
| 1995 |
CREATE TABLE `subscription` ( -- information related to the subscription |
1971 |
CREATE TABLE `subscription` ( -- information related to the subscription |
| 1996 |
`biblionumber` int(11) NOT NULL default 0, -- foreign key for biblio.biblionumber that this subscription is attached to |
1972 |
`biblionumber` int(11) NOT NULL, -- foreign key for biblio.biblionumber that this subscription is attached to |
| 1997 |
`subscriptionid` int(11) NOT NULL auto_increment, -- unique key for this subscription |
1973 |
`subscriptionid` int(11) NOT NULL auto_increment, -- unique key for this subscription |
| 1998 |
`librarian` varchar(100) default '', -- the librarian's username from borrowers.userid |
1974 |
`librarian` varchar(100) default '', -- the librarian's username from borrowers.userid |
| 1999 |
`startdate` date default NULL, -- start date for this subscription |
1975 |
`startdate` date default NULL, -- start date for this subscription |
|
Lines 2037-2045
CREATE TABLE `subscription` ( -- information related to the subscription
Link Here
|
| 2037 |
`previousitemtype` VARCHAR( 10 ) NULL, |
2013 |
`previousitemtype` VARCHAR( 10 ) NULL, |
| 2038 |
`mana_id` int(11) NULL DEFAULT NULL, |
2014 |
`mana_id` int(11) NULL DEFAULT NULL, |
| 2039 |
PRIMARY KEY (`subscriptionid`), |
2015 |
PRIMARY KEY (`subscriptionid`), |
| 2040 |
KEY `by_biblionumber` (`biblionumber`), |
|
|
| 2041 |
CONSTRAINT subscription_ibfk_1 FOREIGN KEY (periodicity) REFERENCES subscription_frequencies (id) ON DELETE SET NULL ON UPDATE CASCADE, |
2016 |
CONSTRAINT subscription_ibfk_1 FOREIGN KEY (periodicity) REFERENCES subscription_frequencies (id) ON DELETE SET NULL ON UPDATE CASCADE, |
| 2042 |
CONSTRAINT subscription_ibfk_2 FOREIGN KEY (numberpattern) REFERENCES subscription_numberpatterns (id) ON DELETE SET NULL ON UPDATE CASCADE |
2017 |
CONSTRAINT subscription_ibfk_2 FOREIGN KEY (numberpattern) REFERENCES subscription_numberpatterns (id) ON DELETE SET NULL ON UPDATE CASCADE, |
|
|
2018 |
CONSTRAINT subscription_ibfk_3 FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 2019 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2020 |
|
| 2021 |
-- |
| 2022 |
-- Table structure for table `serial` |
| 2023 |
-- |
| 2024 |
|
| 2025 |
DROP TABLE IF EXISTS `serial`; |
| 2026 |
CREATE TABLE `serial` ( -- issues related to subscriptions |
| 2027 |
`serialid` int(11) NOT NULL auto_increment, -- unique key for the issue |
| 2028 |
`biblionumber` int(11) NOT NULL, -- foreign key for the biblio.biblionumber that this issue is attached to |
| 2029 |
`subscriptionid` int(11) NOT NULL, -- foreign key to the subscription.subscriptionid that this issue is part of |
| 2030 |
`serialseq` varchar(100) NOT NULL default '', -- issue information (volume, number, etc) |
| 2031 |
`serialseq_x` varchar( 100 ) NULL DEFAULT NULL, -- first part of issue information |
| 2032 |
`serialseq_y` varchar( 100 ) NULL DEFAULT NULL, -- second part of issue information |
| 2033 |
`serialseq_z` varchar( 100 ) NULL DEFAULT NULL, -- third part of issue information |
| 2034 |
`status` tinyint(4) NOT NULL default 0, -- status code for this issue (see manual for full descriptions) |
| 2035 |
`planneddate` date default NULL, -- date expected |
| 2036 |
`notes` MEDIUMTEXT, -- notes |
| 2037 |
`publisheddate` date default NULL, -- date published |
| 2038 |
publisheddatetext varchar(100) default NULL, -- date published (descriptive) |
| 2039 |
`claimdate` date default NULL, -- date claimed |
| 2040 |
claims_count int(11) default 0, -- number of claims made related to this issue |
| 2041 |
`routingnotes` MEDIUMTEXT, -- notes from the routing list |
| 2042 |
PRIMARY KEY (`serialid`), |
| 2043 |
CONSTRAINT serial_ibfk_1 FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2044 |
CONSTRAINT serial_ibfk_2 FOREIGN KEY (subscriptionid) REFERENCES subscription (subscriptionid) ON DELETE CASCADE ON UPDATE CASCADE |
| 2043 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
2045 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2044 |
|
2046 |
|
| 2045 |
-- |
2047 |
-- |
|
Lines 2048-2055
CREATE TABLE `subscription` ( -- information related to the subscription
Link Here
|
| 2048 |
|
2050 |
|
| 2049 |
DROP TABLE IF EXISTS `subscriptionhistory`; |
2051 |
DROP TABLE IF EXISTS `subscriptionhistory`; |
| 2050 |
CREATE TABLE `subscriptionhistory` ( |
2052 |
CREATE TABLE `subscriptionhistory` ( |
| 2051 |
`biblionumber` int(11) NOT NULL default 0, |
2053 |
`biblionumber` int(11) NOT NULL, |
| 2052 |
`subscriptionid` int(11) NOT NULL default 0, |
2054 |
`subscriptionid` int(11) NOT NULL, |
| 2053 |
`histstartdate` date default NULL, |
2055 |
`histstartdate` date default NULL, |
| 2054 |
`histenddate` date default NULL, |
2056 |
`histenddate` date default NULL, |
| 2055 |
`missinglist` LONGTEXT NOT NULL, |
2057 |
`missinglist` LONGTEXT NOT NULL, |
|
Lines 2057-2063
CREATE TABLE `subscriptionhistory` (
Link Here
|
| 2057 |
`opacnote` LONGTEXT NULL, |
2059 |
`opacnote` LONGTEXT NULL, |
| 2058 |
`librariannote` LONGTEXT NULL, |
2060 |
`librariannote` LONGTEXT NULL, |
| 2059 |
PRIMARY KEY (`subscriptionid`), |
2061 |
PRIMARY KEY (`subscriptionid`), |
| 2060 |
KEY `biblionumber` (`biblionumber`) |
2062 |
CONSTRAINT subscription_history_ibfk_1 FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
|
|
2063 |
CONSTRAINT subscription_history_ibfk_2 FOREIGN KEY (subscriptionid) REFERENCES subscription (subscriptionid) ON DELETE CASCADE ON UPDATE CASCADE |
| 2061 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
2064 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2062 |
|
2065 |
|
| 2063 |
-- |
2066 |
-- |