|
Lines 8-14
Link Here
|
| 8 |
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; |
8 |
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; |
| 9 |
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; |
9 |
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; |
| 10 |
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; |
10 |
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; |
| 11 |
/*!40101 SET NAMES utf8 */; |
11 |
/*!40101 SET NAMES utf8mb4 */; |
| 12 |
/*!40103 SET TIME_ZONE='+00:00' */; |
12 |
/*!40103 SET TIME_ZONE='+00:00' */; |
| 13 |
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; |
13 |
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; |
| 14 |
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; |
14 |
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; |
|
Lines 32-38
CREATE TABLE `auth_header` (
Link Here
|
| 32 |
`marcxml` longtext NOT NULL, |
32 |
`marcxml` longtext NOT NULL, |
| 33 |
PRIMARY KEY (`authid`), |
33 |
PRIMARY KEY (`authid`), |
| 34 |
KEY `origincode` (`origincode`) |
34 |
KEY `origincode` (`origincode`) |
| 35 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
35 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 36 |
|
36 |
|
| 37 |
-- |
37 |
-- |
| 38 |
-- Table structure for table `auth_types` |
38 |
-- Table structure for table `auth_types` |
|
Lines 45-51
CREATE TABLE `auth_types` (
Link Here
|
| 45 |
`auth_tag_to_report` varchar(3) NOT NULL default '', |
45 |
`auth_tag_to_report` varchar(3) NOT NULL default '', |
| 46 |
`summary` mediumtext NOT NULL, |
46 |
`summary` mediumtext NOT NULL, |
| 47 |
PRIMARY KEY (`authtypecode`) |
47 |
PRIMARY KEY (`authtypecode`) |
| 48 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
48 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 49 |
|
49 |
|
| 50 |
-- |
50 |
-- |
| 51 |
-- Table structure for table `auth_subfield_structure` |
51 |
-- Table structure for table `auth_subfield_structure` |
|
Lines 73-79
CREATE TABLE `auth_subfield_structure` (
Link Here
|
| 73 |
PRIMARY KEY (`authtypecode`,`tagfield`,`tagsubfield`), |
73 |
PRIMARY KEY (`authtypecode`,`tagfield`,`tagsubfield`), |
| 74 |
KEY `tab` (`authtypecode`,`tab`), |
74 |
KEY `tab` (`authtypecode`,`tab`), |
| 75 |
CONSTRAINT `auth_subfield_structure_ibfk_1` FOREIGN KEY (`authtypecode`) REFERENCES `auth_types` (`authtypecode`) ON DELETE CASCADE ON UPDATE CASCADE |
75 |
CONSTRAINT `auth_subfield_structure_ibfk_1` FOREIGN KEY (`authtypecode`) REFERENCES `auth_types` (`authtypecode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 76 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
76 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 77 |
|
77 |
|
| 78 |
-- |
78 |
-- |
| 79 |
-- Table structure for table `auth_tag_structure` |
79 |
-- Table structure for table `auth_tag_structure` |
|
Lines 90-96
CREATE TABLE `auth_tag_structure` (
Link Here
|
| 90 |
`authorised_value` varchar(10) default NULL, |
90 |
`authorised_value` varchar(10) default NULL, |
| 91 |
PRIMARY KEY (`authtypecode`,`tagfield`), |
91 |
PRIMARY KEY (`authtypecode`,`tagfield`), |
| 92 |
CONSTRAINT `auth_tag_structure_ibfk_1` FOREIGN KEY (`authtypecode`) REFERENCES `auth_types` (`authtypecode`) ON DELETE CASCADE ON UPDATE CASCADE |
92 |
CONSTRAINT `auth_tag_structure_ibfk_1` FOREIGN KEY (`authtypecode`) REFERENCES `auth_types` (`authtypecode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 93 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
93 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 94 |
|
94 |
|
| 95 |
|
95 |
|
| 96 |
-- |
96 |
-- |
|
Lines 99-107
CREATE TABLE `auth_tag_structure` (
Link Here
|
| 99 |
|
99 |
|
| 100 |
DROP TABLE IF EXISTS `authorised_value_categories`; |
100 |
DROP TABLE IF EXISTS `authorised_value_categories`; |
| 101 |
CREATE TABLE `authorised_value_categories` ( |
101 |
CREATE TABLE `authorised_value_categories` ( |
| 102 |
`category_name` varchar(32) COLLATE utf8_unicode_ci NOT NULL DEFAULT '', |
102 |
`category_name` varchar(32) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '', |
| 103 |
PRIMARY KEY (`category_name`) |
103 |
PRIMARY KEY (`category_name`) |
| 104 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
104 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 105 |
|
105 |
|
| 106 |
-- |
106 |
-- |
| 107 |
-- Table structure for table `authorised_values` |
107 |
-- Table structure for table `authorised_values` |
|
Lines 117-126
CREATE TABLE `authorised_values` ( -- stores values for authorized values catego
Link Here
|
| 117 |
`imageurl` varchar(200) default NULL, -- authorized value URL |
117 |
`imageurl` varchar(200) default NULL, -- authorized value URL |
| 118 |
PRIMARY KEY (`id`), |
118 |
PRIMARY KEY (`id`), |
| 119 |
KEY `name` (`category`), |
119 |
KEY `name` (`category`), |
| 120 |
KEY `lib` (`lib`), |
120 |
KEY `lib` (`lib` (191)), |
| 121 |
KEY `auth_value_idx` (`authorised_value`), |
121 |
KEY `auth_value_idx` (`authorised_value`), |
| 122 |
CONSTRAINT `authorised_values_authorised_values_category` FOREIGN KEY (`category`) REFERENCES `authorised_value_categories` (`category_name`) ON DELETE CASCADE ON UPDATE CASCADE |
122 |
CONSTRAINT `authorised_values_authorised_values_category` FOREIGN KEY (`category`) REFERENCES `authorised_value_categories` (`category_name`) ON DELETE CASCADE ON UPDATE CASCADE |
| 123 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
123 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 124 |
|
124 |
|
| 125 |
-- |
125 |
-- |
| 126 |
-- Table structure for table `biblio` |
126 |
-- Table structure for table `biblio` |
|
Lines 142-148
CREATE TABLE `biblio` ( -- table that stores bibliographic information
Link Here
|
| 142 |
`abstract` mediumtext, -- summary from the MARC record (520$a in MARC21) |
142 |
`abstract` mediumtext, -- summary from the MARC record (520$a in MARC21) |
| 143 |
PRIMARY KEY (`biblionumber`), |
143 |
PRIMARY KEY (`biblionumber`), |
| 144 |
KEY `blbnoidx` (`biblionumber`) |
144 |
KEY `blbnoidx` (`biblionumber`) |
| 145 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
145 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 146 |
|
146 |
|
| 147 |
-- |
147 |
-- |
| 148 |
-- Table structure for table `biblio_framework` |
148 |
-- Table structure for table `biblio_framework` |
|
Lines 153-159
CREATE TABLE `biblio_framework` ( -- information about MARC frameworks
Link Here
|
| 153 |
`frameworkcode` varchar(4) NOT NULL default '', -- the unique code assigned to the framework |
153 |
`frameworkcode` varchar(4) NOT NULL default '', -- the unique code assigned to the framework |
| 154 |
`frameworktext` varchar(255) NOT NULL default '', -- the description/name given to the framework |
154 |
`frameworktext` varchar(255) NOT NULL default '', -- the description/name given to the framework |
| 155 |
PRIMARY KEY (`frameworkcode`) |
155 |
PRIMARY KEY (`frameworkcode`) |
| 156 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
156 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 157 |
|
157 |
|
| 158 |
-- |
158 |
-- |
| 159 |
-- Table structure for table `biblioitems` |
159 |
-- Table structure for table `biblioitems` |
|
Lines 200-209
CREATE TABLE `biblioitems` ( -- information related to bibliographic records in
Link Here
|
| 200 |
KEY `isbn` (`isbn`(255)), |
200 |
KEY `isbn` (`isbn`(255)), |
| 201 |
KEY `issn` (`issn`(255)), |
201 |
KEY `issn` (`issn`(255)), |
| 202 |
KEY `ean` (`ean`(255)), |
202 |
KEY `ean` (`ean`(255)), |
| 203 |
KEY `publishercode` (`publishercode`), |
203 |
KEY `publishercode` (`publishercode` (191)), |
| 204 |
KEY `timestamp` (`timestamp`), |
204 |
KEY `timestamp` (`timestamp`), |
| 205 |
CONSTRAINT `biblioitems_ibfk_1` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
205 |
CONSTRAINT `biblioitems_ibfk_1` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 206 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
206 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 207 |
|
207 |
|
| 208 |
-- |
208 |
-- |
| 209 |
-- Table structure for table `borrower_attribute_types` |
209 |
-- Table structure for table `borrower_attribute_types` |
|
Lines 224-230
CREATE TABLE `borrower_attribute_types` ( -- definitions for custom patron field
Link Here
|
| 224 |
`class` VARCHAR(255) NOT NULL DEFAULT '',-- defines a class for an attribute_type |
224 |
`class` VARCHAR(255) NOT NULL DEFAULT '',-- defines a class for an attribute_type |
| 225 |
PRIMARY KEY (`code`), |
225 |
PRIMARY KEY (`code`), |
| 226 |
KEY `auth_val_cat_idx` (`authorised_value_category`) |
226 |
KEY `auth_val_cat_idx` (`authorised_value_category`) |
| 227 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
227 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 228 |
|
228 |
|
| 229 |
-- |
229 |
-- |
| 230 |
-- Table structure for table `borrower_password_recovery` |
230 |
-- Table structure for table `borrower_password_recovery` |
|
Lines 237-243
CREATE TABLE IF NOT EXISTS `borrower_password_recovery` ( -- holds information a
Link Here
|
| 237 |
`valid_until` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, -- a time limit on the password recovery attempt |
237 |
`valid_until` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, -- a time limit on the password recovery attempt |
| 238 |
PRIMARY KEY (`borrowernumber`), |
238 |
PRIMARY KEY (`borrowernumber`), |
| 239 |
KEY borrowernumber (borrowernumber) |
239 |
KEY borrowernumber (borrowernumber) |
| 240 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
240 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 241 |
|
241 |
|
| 242 |
-- |
242 |
-- |
| 243 |
-- Table structure for table `branches` |
243 |
-- Table structure for table `branches` |
|
Lines 268-274
CREATE TABLE `branches` ( -- information about your libraries or branches are st
Link Here
|
| 268 |
`geolocation` VARCHAR(255) default NULL, -- geolocation of your library |
268 |
`geolocation` VARCHAR(255) default NULL, -- geolocation of your library |
| 269 |
`marcorgcode` VARCHAR(16) default NULL, -- MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode |
269 |
`marcorgcode` VARCHAR(16) default NULL, -- MARC Organization Code, see http://www.loc.gov/marc/organizations/orgshome.html, when empty defaults to syspref MARCOrgCode |
| 270 |
PRIMARY KEY (`branchcode`) |
270 |
PRIMARY KEY (`branchcode`) |
| 271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 272 |
|
272 |
|
| 273 |
-- |
273 |
-- |
| 274 |
-- Table structure for table `browser` |
274 |
-- Table structure for table `browser` |
|
Lines 280-286
CREATE TABLE `browser` (
Link Here
|
| 280 |
`description` varchar(255) NOT NULL, |
280 |
`description` varchar(255) NOT NULL, |
| 281 |
`number` bigint(20) NOT NULL, |
281 |
`number` bigint(20) NOT NULL, |
| 282 |
`endnode` tinyint(4) NOT NULL |
282 |
`endnode` tinyint(4) NOT NULL |
| 283 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
283 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 284 |
|
284 |
|
| 285 |
-- |
285 |
-- |
| 286 |
-- Table structure for table `categories` |
286 |
-- Table structure for table `categories` |
|
Lines 307-313
CREATE TABLE `categories` ( -- this table shows information related to Koha patr
Link Here
|
| 307 |
`checkprevcheckout` varchar(7) NOT NULL default 'inherit', -- produce a warning for this patron category if this item has previously been checked out to this patron if 'yes', not if 'no', defer to syspref setting if 'inherit'. |
307 |
`checkprevcheckout` varchar(7) NOT NULL default 'inherit', -- produce a warning for this patron category if this item has previously been checked out to this patron if 'yes', not if 'no', defer to syspref setting if 'inherit'. |
| 308 |
PRIMARY KEY (`categorycode`), |
308 |
PRIMARY KEY (`categorycode`), |
| 309 |
UNIQUE KEY `categorycode` (`categorycode`) |
309 |
UNIQUE KEY `categorycode` (`categorycode`) |
| 310 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
310 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 311 |
|
311 |
|
| 312 |
-- |
312 |
-- |
| 313 |
-- Table: collections |
313 |
-- Table: collections |
|
Lines 319-325
CREATE TABLE collections (
Link Here
|
| 319 |
colDesc text NOT NULL, |
319 |
colDesc text NOT NULL, |
| 320 |
colBranchcode varchar(10) DEFAULT NULL, -- 'branchcode for branch where item should be held.' |
320 |
colBranchcode varchar(10) DEFAULT NULL, -- 'branchcode for branch where item should be held.' |
| 321 |
PRIMARY KEY (colId) |
321 |
PRIMARY KEY (colId) |
| 322 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
322 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 323 |
|
323 |
|
| 324 |
-- |
324 |
-- |
| 325 |
-- Constraints for table `collections` |
325 |
-- Constraints for table `collections` |
|
Lines 337-343
CREATE TABLE collections_tracking (
Link Here
|
| 337 |
colId integer(11) NOT NULL DEFAULT 0 comment 'collections.colId', |
337 |
colId integer(11) NOT NULL DEFAULT 0 comment 'collections.colId', |
| 338 |
itemnumber integer(11) NOT NULL DEFAULT 0 comment 'items.itemnumber', |
338 |
itemnumber integer(11) NOT NULL DEFAULT 0 comment 'items.itemnumber', |
| 339 |
PRIMARY KEY (collections_tracking_id) |
339 |
PRIMARY KEY (collections_tracking_id) |
| 340 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
340 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 341 |
|
341 |
|
| 342 |
-- |
342 |
-- |
| 343 |
-- Table structure for table `branch_borrower_circ_rules` |
343 |
-- Table structure for table `branch_borrower_circ_rules` |
|
Lines 354-360
CREATE TABLE `branch_borrower_circ_rules` ( -- includes default circulation rule
Link Here
|
| 354 |
ON DELETE CASCADE ON UPDATE CASCADE, |
354 |
ON DELETE CASCADE ON UPDATE CASCADE, |
| 355 |
CONSTRAINT `branch_borrower_circ_rules_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
355 |
CONSTRAINT `branch_borrower_circ_rules_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
| 356 |
ON DELETE CASCADE ON UPDATE CASCADE |
356 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 357 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
357 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 358 |
|
358 |
|
| 359 |
-- |
359 |
-- |
| 360 |
-- Table structure for table `default_borrower_circ_rules` |
360 |
-- Table structure for table `default_borrower_circ_rules` |
|
Lines 368-374
CREATE TABLE `default_borrower_circ_rules` ( -- default checkout rules found und
Link Here
|
| 368 |
PRIMARY KEY (`categorycode`), |
368 |
PRIMARY KEY (`categorycode`), |
| 369 |
CONSTRAINT `borrower_borrower_circ_rules_ibfk_1` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`) |
369 |
CONSTRAINT `borrower_borrower_circ_rules_ibfk_1` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`) |
| 370 |
ON DELETE CASCADE ON UPDATE CASCADE |
370 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 371 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
371 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 372 |
|
372 |
|
| 373 |
-- |
373 |
-- |
| 374 |
-- Table structure for table `default_branch_circ_rules` |
374 |
-- Table structure for table `default_branch_circ_rules` |
|
Lines 385-391
CREATE TABLE `default_branch_circ_rules` (
Link Here
|
| 385 |
PRIMARY KEY (`branchcode`), |
385 |
PRIMARY KEY (`branchcode`), |
| 386 |
CONSTRAINT `default_branch_circ_rules_ibfk_1` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
386 |
CONSTRAINT `default_branch_circ_rules_ibfk_1` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
| 387 |
ON DELETE CASCADE ON UPDATE CASCADE |
387 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 388 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
388 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 389 |
|
389 |
|
| 390 |
-- |
390 |
-- |
| 391 |
-- Table structure for table `default_circ_rules` |
391 |
-- Table structure for table `default_circ_rules` |
|
Lines 400-406
CREATE TABLE `default_circ_rules` (
Link Here
|
| 400 |
hold_fulfillment_policy ENUM('any', 'homebranch', 'holdingbranch') NOT NULL DEFAULT 'any', -- limit trapping of holds by branchcode |
400 |
hold_fulfillment_policy ENUM('any', 'homebranch', 'holdingbranch') NOT NULL DEFAULT 'any', -- limit trapping of holds by branchcode |
| 401 |
`returnbranch` varchar(15) default NULL, |
401 |
`returnbranch` varchar(15) default NULL, |
| 402 |
PRIMARY KEY (`singleton`) |
402 |
PRIMARY KEY (`singleton`) |
| 403 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
403 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 404 |
|
404 |
|
| 405 |
-- |
405 |
-- |
| 406 |
-- Table structure for table `cities` |
406 |
-- Table structure for table `cities` |
|
Lines 414-420
CREATE TABLE `cities` ( -- authorized values for cities/states/countries to choo
Link Here
|
| 414 |
`city_country` VARCHAR( 100 ) NULL DEFAULT NULL, -- name of the country |
414 |
`city_country` VARCHAR( 100 ) NULL DEFAULT NULL, -- name of the country |
| 415 |
`city_zipcode` varchar(20) default NULL, -- zip or postal code |
415 |
`city_zipcode` varchar(20) default NULL, -- zip or postal code |
| 416 |
PRIMARY KEY (`cityid`) |
416 |
PRIMARY KEY (`cityid`) |
| 417 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
417 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 418 |
|
418 |
|
| 419 |
-- |
419 |
-- |
| 420 |
-- Table structure for table `class_sort_rules` |
420 |
-- Table structure for table `class_sort_rules` |
|
Lines 427-433
CREATE TABLE `class_sort_rules` (
Link Here
|
| 427 |
`sort_routine` varchar(30) NOT NULL default '', |
427 |
`sort_routine` varchar(30) NOT NULL default '', |
| 428 |
PRIMARY KEY (`class_sort_rule`), |
428 |
PRIMARY KEY (`class_sort_rule`), |
| 429 |
UNIQUE KEY `class_sort_rule_idx` (`class_sort_rule`) |
429 |
UNIQUE KEY `class_sort_rule_idx` (`class_sort_rule`) |
| 430 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
430 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 431 |
|
431 |
|
| 432 |
-- |
432 |
-- |
| 433 |
-- Table structure for table `class_sources` |
433 |
-- Table structure for table `class_sources` |
|
Lines 443-449
CREATE TABLE `class_sources` (
Link Here
|
| 443 |
UNIQUE KEY `cn_source_idx` (`cn_source`), |
443 |
UNIQUE KEY `cn_source_idx` (`cn_source`), |
| 444 |
KEY `used_idx` (`used`), |
444 |
KEY `used_idx` (`used`), |
| 445 |
CONSTRAINT `class_source_ibfk_1` FOREIGN KEY (`class_sort_rule`) REFERENCES `class_sort_rules` (`class_sort_rule`) |
445 |
CONSTRAINT `class_source_ibfk_1` FOREIGN KEY (`class_sort_rule`) REFERENCES `class_sort_rules` (`class_sort_rule`) |
| 446 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
446 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 447 |
|
447 |
|
| 448 |
-- |
448 |
-- |
| 449 |
-- Table structure for table `currency` |
449 |
-- Table structure for table `currency` |
|
Lines 459-465
CREATE TABLE `currency` (
Link Here
|
| 459 |
`active` tinyint(1) default NULL, |
459 |
`active` tinyint(1) default NULL, |
| 460 |
`archived` tinyint(1) DEFAULT 0, |
460 |
`archived` tinyint(1) DEFAULT 0, |
| 461 |
PRIMARY KEY (`currency`) |
461 |
PRIMARY KEY (`currency`) |
| 462 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
462 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 463 |
|
463 |
|
| 464 |
-- |
464 |
-- |
| 465 |
-- Table structure for table `deletedbiblio` |
465 |
-- Table structure for table `deletedbiblio` |
|
Lines 481-487
CREATE TABLE `deletedbiblio` ( -- stores information about bibliographic records
Link Here
|
| 481 |
`abstract` mediumtext, -- summary from the MARC record (520$a in MARC21) |
481 |
`abstract` mediumtext, -- summary from the MARC record (520$a in MARC21) |
| 482 |
PRIMARY KEY (`biblionumber`), |
482 |
PRIMARY KEY (`biblionumber`), |
| 483 |
KEY `blbnoidx` (`biblionumber`) |
483 |
KEY `blbnoidx` (`biblionumber`) |
| 484 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
484 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 485 |
|
485 |
|
| 486 |
-- |
486 |
-- |
| 487 |
-- Table structure for table `deletedbiblioitems` |
487 |
-- Table structure for table `deletedbiblioitems` |
|
Lines 527-535
CREATE TABLE `deletedbiblioitems` ( -- information about bibliographic records t
Link Here
|
| 527 |
KEY `itemtype_idx` (`itemtype`), |
527 |
KEY `itemtype_idx` (`itemtype`), |
| 528 |
KEY `isbn` (`isbn`(255)), |
528 |
KEY `isbn` (`isbn`(255)), |
| 529 |
KEY `ean` (`ean`(255)), |
529 |
KEY `ean` (`ean`(255)), |
| 530 |
KEY `publishercode` (`publishercode`), |
530 |
KEY `publishercode` (`publishercode` (191)), |
| 531 |
KEY `timestamp` (`timestamp`) |
531 |
KEY `timestamp` (`timestamp`) |
| 532 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
532 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 533 |
|
533 |
|
| 534 |
-- |
534 |
-- |
| 535 |
-- Table structure for table `deletedborrowers` |
535 |
-- Table structure for table `deletedborrowers` |
|
Lines 614-620
CREATE TABLE `deletedborrowers` ( -- stores data related to the patrons/borrower
Link Here
|
| 614 |
KEY borrowernumber (borrowernumber), |
614 |
KEY borrowernumber (borrowernumber), |
| 615 |
KEY `cardnumber` (`cardnumber`), |
615 |
KEY `cardnumber` (`cardnumber`), |
| 616 |
KEY `sms_provider_id` (`sms_provider_id`) |
616 |
KEY `sms_provider_id` (`sms_provider_id`) |
| 617 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
617 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 618 |
|
618 |
|
| 619 |
-- |
619 |
-- |
| 620 |
-- Table structure for table `deleteditems` |
620 |
-- Table structure for table `deleteditems` |
|
Lines 675-681
CREATE TABLE `deleteditems` (
Link Here
|
| 675 |
KEY `delholdingbranch` (`holdingbranch`), |
675 |
KEY `delholdingbranch` (`holdingbranch`), |
| 676 |
KEY `itype_idx` (`itype`), |
676 |
KEY `itype_idx` (`itype`), |
| 677 |
KEY `timestamp` (`timestamp`) |
677 |
KEY `timestamp` (`timestamp`) |
| 678 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
678 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 679 |
|
679 |
|
| 680 |
-- |
680 |
-- |
| 681 |
-- Table structure for table `export_format` |
681 |
-- Table structure for table `export_format` |
|
Lines 694-700
CREATE TABLE `export_format` (
Link Here
|
| 694 |
`type` varchar(255) DEFAULT 'marc', |
694 |
`type` varchar(255) DEFAULT 'marc', |
| 695 |
`used_for` varchar(255) DEFAULT 'export_records', |
695 |
`used_for` varchar(255) DEFAULT 'export_records', |
| 696 |
PRIMARY KEY (`export_format_id`) |
696 |
PRIMARY KEY (`export_format_id`) |
| 697 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='Used for CSV export'; |
697 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='Used for CSV export'; |
| 698 |
|
698 |
|
| 699 |
-- |
699 |
-- |
| 700 |
-- Table structure for table `import_batches` |
700 |
-- Table structure for table `import_batches` |
|
Lines 719-725
CREATE TABLE `import_batches` ( -- information about batches of marc records tha
Link Here
|
| 719 |
`comments` mediumtext, -- any comments added when the file was uploaded |
719 |
`comments` mediumtext, -- any comments added when the file was uploaded |
| 720 |
PRIMARY KEY (`import_batch_id`), |
720 |
PRIMARY KEY (`import_batch_id`), |
| 721 |
KEY `branchcode` (`branchcode`) |
721 |
KEY `branchcode` (`branchcode`) |
| 722 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
722 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 723 |
|
723 |
|
| 724 |
-- |
724 |
-- |
| 725 |
-- Table structure for table `import_records` |
725 |
-- Table structure for table `import_records` |
|
Lines 748-754
CREATE TABLE `import_records` (
Link Here
|
| 748 |
KEY `branchcode` (`branchcode`), |
748 |
KEY `branchcode` (`branchcode`), |
| 749 |
KEY `batch_sequence` (`import_batch_id`, `record_sequence`), |
749 |
KEY `batch_sequence` (`import_batch_id`, `record_sequence`), |
| 750 |
KEY `batch_id_record_type` (`import_batch_id`,`record_type`) |
750 |
KEY `batch_id_record_type` (`import_batch_id`,`record_type`) |
| 751 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
751 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 752 |
|
752 |
|
| 753 |
-- |
753 |
-- |
| 754 |
-- Table structure for `import_record_matches` |
754 |
-- Table structure for `import_record_matches` |
|
Lines 761-767
CREATE TABLE `import_record_matches` ( -- matches found when importing a batch o
Link Here
|
| 761 |
CONSTRAINT `import_record_matches_ibfk_1` FOREIGN KEY (`import_record_id`) |
761 |
CONSTRAINT `import_record_matches_ibfk_1` FOREIGN KEY (`import_record_id`) |
| 762 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
762 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 763 |
KEY `record_score` (`import_record_id`, `score`) |
763 |
KEY `record_score` (`import_record_id`, `score`) |
| 764 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
764 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 765 |
|
765 |
|
| 766 |
-- |
766 |
-- |
| 767 |
-- Table structure for table `import_auths` |
767 |
-- Table structure for table `import_auths` |
|
Lines 777-783
CREATE TABLE `import_auths` (
Link Here
|
| 777 |
CONSTRAINT `import_auths_ibfk_1` FOREIGN KEY (`import_record_id`) |
777 |
CONSTRAINT `import_auths_ibfk_1` FOREIGN KEY (`import_record_id`) |
| 778 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
778 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 779 |
KEY `matched_authid` (`matched_authid`) |
779 |
KEY `matched_authid` (`matched_authid`) |
| 780 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
780 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 781 |
|
781 |
|
| 782 |
-- |
782 |
-- |
| 783 |
-- Table structure for table `import_biblios` |
783 |
-- Table structure for table `import_biblios` |
|
Lines 799-805
CREATE TABLE `import_biblios` (
Link Here
|
| 799 |
KEY `matched_biblionumber` (`matched_biblionumber`), |
799 |
KEY `matched_biblionumber` (`matched_biblionumber`), |
| 800 |
KEY `title` (`title`), |
800 |
KEY `title` (`title`), |
| 801 |
KEY `isbn` (`isbn`) |
801 |
KEY `isbn` (`isbn`) |
| 802 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
802 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 803 |
|
803 |
|
| 804 |
-- |
804 |
-- |
| 805 |
-- Table structure for table `import_items` |
805 |
-- Table structure for table `import_items` |
|
Lines 819-825
CREATE TABLE `import_items` (
Link Here
|
| 819 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
819 |
REFERENCES `import_records` (`import_record_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 820 |
KEY `itemnumber` (`itemnumber`), |
820 |
KEY `itemnumber` (`itemnumber`), |
| 821 |
KEY `branchcode` (`branchcode`) |
821 |
KEY `branchcode` (`branchcode`) |
| 822 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
822 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 823 |
|
823 |
|
| 824 |
-- |
824 |
-- |
| 825 |
-- Table structure for table `issuingrules` |
825 |
-- Table structure for table `issuingrules` |
|
Lines 863-869
CREATE TABLE `issuingrules` ( -- circulation and fine rules
Link Here
|
| 863 |
PRIMARY KEY (`branchcode`,`categorycode`,`itemtype`), |
863 |
PRIMARY KEY (`branchcode`,`categorycode`,`itemtype`), |
| 864 |
KEY `categorycode` (`categorycode`), |
864 |
KEY `categorycode` (`categorycode`), |
| 865 |
KEY `itemtype` (`itemtype`) |
865 |
KEY `itemtype` (`itemtype`) |
| 866 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
866 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 867 |
|
867 |
|
| 868 |
-- |
868 |
-- |
| 869 |
-- Table structure for table `refund_lost_item_fee_rules` |
869 |
-- Table structure for table `refund_lost_item_fee_rules` |
|
Lines 874-880
CREATE TABLE `refund_lost_item_fee_rules` ( -- refund lost item fee rules tbale
Link Here
|
| 874 |
`branchcode` varchar(10) NOT NULL default '', -- the branch this rule is for (branches.branchcode) |
874 |
`branchcode` varchar(10) NOT NULL default '', -- the branch this rule is for (branches.branchcode) |
| 875 |
`refund` tinyint(1) NOT NULL default 0, -- control wether to refund lost item fees on return |
875 |
`refund` tinyint(1) NOT NULL default 0, -- control wether to refund lost item fees on return |
| 876 |
PRIMARY KEY (`branchcode`) |
876 |
PRIMARY KEY (`branchcode`) |
| 877 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
877 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 878 |
|
878 |
|
| 879 |
-- |
879 |
-- |
| 880 |
-- Table structure for table `items` |
880 |
-- Table structure for table `items` |
|
Lines 933-939
CREATE TABLE `items` ( -- holdings/item information
Link Here
|
| 933 |
KEY `itembibnoidx` (`biblionumber`), |
933 |
KEY `itembibnoidx` (`biblionumber`), |
| 934 |
KEY `homebranch` (`homebranch`), |
934 |
KEY `homebranch` (`homebranch`), |
| 935 |
KEY `holdingbranch` (`holdingbranch`), |
935 |
KEY `holdingbranch` (`holdingbranch`), |
| 936 |
KEY `itemcallnumber` (`itemcallnumber`), |
936 |
KEY `itemcallnumber` (`itemcallnumber` (191)), |
| 937 |
KEY `items_location` (`location`), |
937 |
KEY `items_location` (`location`), |
| 938 |
KEY `items_ccode` (`ccode`), |
938 |
KEY `items_ccode` (`ccode`), |
| 939 |
KEY `itype_idx` (`itype`), |
939 |
KEY `itype_idx` (`itype`), |
|
Lines 942-948
CREATE TABLE `items` ( -- holdings/item information
Link Here
|
| 942 |
CONSTRAINT `items_ibfk_2` FOREIGN KEY (`homebranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE, |
942 |
CONSTRAINT `items_ibfk_2` FOREIGN KEY (`homebranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE, |
| 943 |
CONSTRAINT `items_ibfk_3` FOREIGN KEY (`holdingbranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE, |
943 |
CONSTRAINT `items_ibfk_3` FOREIGN KEY (`holdingbranch`) REFERENCES `branches` (`branchcode`) ON UPDATE CASCADE, |
| 944 |
CONSTRAINT `items_ibfk_4` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
944 |
CONSTRAINT `items_ibfk_4` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 945 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
945 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 946 |
|
946 |
|
| 947 |
-- |
947 |
-- |
| 948 |
-- Table structure for table `itemtypes` |
948 |
-- Table structure for table `itemtypes` |
|
Lines 965-971
CREATE TABLE `itemtypes` ( -- defines the item types
Link Here
|
| 965 |
searchcategory varchar(80) default NULL, -- Group this item type with others with the same value on OPAC search options |
965 |
searchcategory varchar(80) default NULL, -- Group this item type with others with the same value on OPAC search options |
| 966 |
PRIMARY KEY (`itemtype`), |
966 |
PRIMARY KEY (`itemtype`), |
| 967 |
UNIQUE KEY `itemtype` (`itemtype`) |
967 |
UNIQUE KEY `itemtype` (`itemtype`) |
| 968 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
968 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 969 |
|
969 |
|
| 970 |
-- |
970 |
-- |
| 971 |
-- Table structure for table `default_branch_item_rules` |
971 |
-- Table structure for table `default_branch_item_rules` |
|
Lines 980-986
CREATE TABLE `default_branch_item_rules` (
Link Here
|
| 980 |
PRIMARY KEY (`itemtype`), |
980 |
PRIMARY KEY (`itemtype`), |
| 981 |
CONSTRAINT `default_branch_item_rules_ibfk_1` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) |
981 |
CONSTRAINT `default_branch_item_rules_ibfk_1` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) |
| 982 |
ON DELETE CASCADE ON UPDATE CASCADE |
982 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 983 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
983 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 984 |
|
984 |
|
| 985 |
-- |
985 |
-- |
| 986 |
-- Table structure for table `branchtransfers` |
986 |
-- Table structure for table `branchtransfers` |
|
Lines 1002-1008
CREATE TABLE `branchtransfers` ( -- information for items that are in transit be
Link Here
|
| 1002 |
CONSTRAINT `branchtransfers_ibfk_1` FOREIGN KEY (`frombranch`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
1002 |
CONSTRAINT `branchtransfers_ibfk_1` FOREIGN KEY (`frombranch`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1003 |
CONSTRAINT `branchtransfers_ibfk_2` FOREIGN KEY (`tobranch`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
1003 |
CONSTRAINT `branchtransfers_ibfk_2` FOREIGN KEY (`tobranch`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1004 |
CONSTRAINT `branchtransfers_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
1004 |
CONSTRAINT `branchtransfers_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1005 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1005 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1006 |
|
1006 |
|
| 1007 |
-- |
1007 |
-- |
| 1008 |
-- Table structure for table `branch_item_rules` |
1008 |
-- Table structure for table `branch_item_rules` |
|
Lines 1021-1027
CREATE TABLE `branch_item_rules` ( -- information entered in the circulation and
Link Here
|
| 1021 |
ON DELETE CASCADE ON UPDATE CASCADE, |
1021 |
ON DELETE CASCADE ON UPDATE CASCADE, |
| 1022 |
CONSTRAINT `branch_item_rules_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
1022 |
CONSTRAINT `branch_item_rules_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) |
| 1023 |
ON DELETE CASCADE ON UPDATE CASCADE |
1023 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 1024 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1024 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1025 |
|
1025 |
|
| 1026 |
-- |
1026 |
-- |
| 1027 |
-- Table structure for table `creator_images` |
1027 |
-- Table structure for table `creator_images` |
|
Lines 1036-1042
CREATE TABLE `creator_images` (
Link Here
|
| 1036 |
`image_name` char(20) NOT NULL DEFAULT 'DEFAULT', |
1036 |
`image_name` char(20) NOT NULL DEFAULT 'DEFAULT', |
| 1037 |
PRIMARY KEY (`image_id`), |
1037 |
PRIMARY KEY (`image_id`), |
| 1038 |
UNIQUE KEY `image_name_index` (`image_name`) |
1038 |
UNIQUE KEY `image_name_index` (`image_name`) |
| 1039 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1039 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1040 |
|
1040 |
|
| 1041 |
-- |
1041 |
-- |
| 1042 |
-- Table structure for table `creator_layouts` |
1042 |
-- Table structure for table `creator_layouts` |
|
Lines 1053-1068
CREATE TABLE `creator_layouts` (
Link Here
|
| 1053 |
`layout_name` char(25) NOT NULL DEFAULT 'DEFAULT', |
1053 |
`layout_name` char(25) NOT NULL DEFAULT 'DEFAULT', |
| 1054 |
`guidebox` int(1) DEFAULT '0', |
1054 |
`guidebox` int(1) DEFAULT '0', |
| 1055 |
`oblique_title` int(1) DEFAULT '1', |
1055 |
`oblique_title` int(1) DEFAULT '1', |
| 1056 |
`font` char(10) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT 'TR', |
1056 |
`font` char(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'TR', |
| 1057 |
`font_size` int(4) NOT NULL DEFAULT '10', |
1057 |
`font_size` int(4) NOT NULL DEFAULT '10', |
| 1058 |
`units` char(20) NOT NULL DEFAULT 'POINT', |
1058 |
`units` char(20) NOT NULL DEFAULT 'POINT', |
| 1059 |
`callnum_split` int(1) DEFAULT '0', |
1059 |
`callnum_split` int(1) DEFAULT '0', |
| 1060 |
`text_justify` char(1) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL DEFAULT 'L', |
1060 |
`text_justify` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'L', |
| 1061 |
`format_string` varchar(210) NOT NULL DEFAULT 'barcode', |
1061 |
`format_string` varchar(210) NOT NULL DEFAULT 'barcode', |
| 1062 |
`layout_xml` text NOT NULL, |
1062 |
`layout_xml` text NOT NULL, |
| 1063 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
1063 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
| 1064 |
PRIMARY KEY (`layout_id`) |
1064 |
PRIMARY KEY (`layout_id`) |
| 1065 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1065 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1066 |
|
1066 |
|
| 1067 |
-- |
1067 |
-- |
| 1068 |
-- Table structure for table `creator_templates` |
1068 |
-- Table structure for table `creator_templates` |
|
Lines 1092-1098
CREATE TABLE `creator_templates` (
Link Here
|
| 1092 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
1092 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
| 1093 |
PRIMARY KEY (`template_id`), |
1093 |
PRIMARY KEY (`template_id`), |
| 1094 |
KEY `template_profile_fk_constraint` (`profile_id`) |
1094 |
KEY `template_profile_fk_constraint` (`profile_id`) |
| 1095 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1095 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1096 |
|
1096 |
|
| 1097 |
-- |
1097 |
-- |
| 1098 |
-- Table structure for table `marc_subfield_structure` |
1098 |
-- Table structure for table `marc_subfield_structure` |
|
Lines 1123-1129
CREATE TABLE `marc_subfield_structure` (
Link Here
|
| 1123 |
KEY `tab` (`frameworkcode`,`tab`), |
1123 |
KEY `tab` (`frameworkcode`,`tab`), |
| 1124 |
KEY `kohafield` (`frameworkcode`,`kohafield`), |
1124 |
KEY `kohafield` (`frameworkcode`,`kohafield`), |
| 1125 |
CONSTRAINT `marc_subfield_structure_ibfk_1` FOREIGN KEY (`authorised_value`) REFERENCES `authorised_value_categories` (`category_name`) ON DELETE SET NULL ON UPDATE CASCADE |
1125 |
CONSTRAINT `marc_subfield_structure_ibfk_1` FOREIGN KEY (`authorised_value`) REFERENCES `authorised_value_categories` (`category_name`) ON DELETE SET NULL ON UPDATE CASCADE |
| 1126 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1126 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1127 |
|
1127 |
|
| 1128 |
-- |
1128 |
-- |
| 1129 |
-- Table structure for table `marc_tag_structure` |
1129 |
-- Table structure for table `marc_tag_structure` |
|
Lines 1139-1145
CREATE TABLE `marc_tag_structure` (
Link Here
|
| 1139 |
`authorised_value` varchar(10) default NULL, |
1139 |
`authorised_value` varchar(10) default NULL, |
| 1140 |
`frameworkcode` varchar(4) NOT NULL default '', |
1140 |
`frameworkcode` varchar(4) NOT NULL default '', |
| 1141 |
PRIMARY KEY (`frameworkcode`,`tagfield`) |
1141 |
PRIMARY KEY (`frameworkcode`,`tagfield`) |
| 1142 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1142 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1143 |
|
1143 |
|
| 1144 |
-- |
1144 |
-- |
| 1145 |
-- Table structure for table `marc_matchers` |
1145 |
-- Table structure for table `marc_matchers` |
|
Lines 1155-1161
CREATE TABLE `marc_matchers` (
Link Here
|
| 1155 |
PRIMARY KEY (`matcher_id`), |
1155 |
PRIMARY KEY (`matcher_id`), |
| 1156 |
KEY `code` (`code`), |
1156 |
KEY `code` (`code`), |
| 1157 |
KEY `record_type` (`record_type`) |
1157 |
KEY `record_type` (`record_type`) |
| 1158 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1158 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1159 |
|
1159 |
|
| 1160 |
-- |
1160 |
-- |
| 1161 |
-- Table structure for table `matchpoints` |
1161 |
-- Table structure for table `matchpoints` |
|
Lines 1169-1175
CREATE TABLE `matchpoints` (
Link Here
|
| 1169 |
PRIMARY KEY (`matchpoint_id`), |
1169 |
PRIMARY KEY (`matchpoint_id`), |
| 1170 |
CONSTRAINT `matchpoints_ifbk_1` FOREIGN KEY (`matcher_id`) |
1170 |
CONSTRAINT `matchpoints_ifbk_1` FOREIGN KEY (`matcher_id`) |
| 1171 |
REFERENCES `marc_matchers` (`matcher_id`) ON DELETE CASCADE ON UPDATE CASCADE |
1171 |
REFERENCES `marc_matchers` (`matcher_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1172 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1172 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1173 |
|
1173 |
|
| 1174 |
|
1174 |
|
| 1175 |
-- |
1175 |
-- |
|
Lines 1188-1194
CREATE TABLE `matchpoint_components` (
Link Here
|
| 1188 |
KEY `by_sequence` (`matchpoint_id`, `sequence`), |
1188 |
KEY `by_sequence` (`matchpoint_id`, `sequence`), |
| 1189 |
CONSTRAINT `matchpoint_components_ifbk_1` FOREIGN KEY (`matchpoint_id`) |
1189 |
CONSTRAINT `matchpoint_components_ifbk_1` FOREIGN KEY (`matchpoint_id`) |
| 1190 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
1190 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1191 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1191 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1192 |
|
1192 |
|
| 1193 |
-- |
1193 |
-- |
| 1194 |
-- Table structure for table `matcher_component_norms` |
1194 |
-- Table structure for table `matcher_component_norms` |
|
Lines 1201-1207
CREATE TABLE `matchpoint_component_norms` (
Link Here
|
| 1201 |
KEY `matchpoint_component_norms` (`matchpoint_component_id`, `sequence`), |
1201 |
KEY `matchpoint_component_norms` (`matchpoint_component_id`, `sequence`), |
| 1202 |
CONSTRAINT `matchpoint_component_norms_ifbk_1` FOREIGN KEY (`matchpoint_component_id`) |
1202 |
CONSTRAINT `matchpoint_component_norms_ifbk_1` FOREIGN KEY (`matchpoint_component_id`) |
| 1203 |
REFERENCES `matchpoint_components` (`matchpoint_component_id`) ON DELETE CASCADE ON UPDATE CASCADE |
1203 |
REFERENCES `matchpoint_components` (`matchpoint_component_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1204 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1204 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1205 |
|
1205 |
|
| 1206 |
-- |
1206 |
-- |
| 1207 |
-- Table structure for table `matcher_matchpoints` |
1207 |
-- Table structure for table `matcher_matchpoints` |
|
Lines 1214-1220
CREATE TABLE `matcher_matchpoints` (
Link Here
|
| 1214 |
REFERENCES `marc_matchers` (`matcher_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
1214 |
REFERENCES `marc_matchers` (`matcher_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1215 |
CONSTRAINT `matcher_matchpoints_ifbk_2` FOREIGN KEY (`matchpoint_id`) |
1215 |
CONSTRAINT `matcher_matchpoints_ifbk_2` FOREIGN KEY (`matchpoint_id`) |
| 1216 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
1216 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1217 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1217 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1218 |
|
1218 |
|
| 1219 |
-- |
1219 |
-- |
| 1220 |
-- Table structure for table `matchchecks` |
1220 |
-- Table structure for table `matchchecks` |
|
Lines 1232-1238
CREATE TABLE `matchchecks` (
Link Here
|
| 1232 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
1232 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1233 |
CONSTRAINT `matcher_matchchecks_ifbk_3` FOREIGN KEY (`target_matchpoint_id`) |
1233 |
CONSTRAINT `matcher_matchchecks_ifbk_3` FOREIGN KEY (`target_matchpoint_id`) |
| 1234 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
1234 |
REFERENCES `matchpoints` (`matchpoint_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1235 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1235 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1236 |
|
1236 |
|
| 1237 |
-- |
1237 |
-- |
| 1238 |
-- Table structure for table `need_merge_authorities` |
1238 |
-- Table structure for table `need_merge_authorities` |
|
Lines 1248-1254
CREATE TABLE `need_merge_authorities` ( -- keeping track of authority records st
Link Here
|
| 1248 |
`done` tinyint DEFAULT 0 -- indication whether merge has been executed (0=not done, 1=done, 2=in progress) |
1248 |
`done` tinyint DEFAULT 0 -- indication whether merge has been executed (0=not done, 1=done, 2=in progress) |
| 1249 |
-- Note: authid and authid_new should NOT be FOREIGN keys ! |
1249 |
-- Note: authid and authid_new should NOT be FOREIGN keys ! |
| 1250 |
-- authid may have been deleted; authid_new may be zero |
1250 |
-- authid may have been deleted; authid_new may be zero |
| 1251 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1251 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1252 |
|
1252 |
|
| 1253 |
-- |
1253 |
-- |
| 1254 |
-- Table structure for table `oai_sets` |
1254 |
-- Table structure for table `oai_sets` |
|
Lines 1260-1266
CREATE TABLE `oai_sets` (
Link Here
|
| 1260 |
`spec` varchar(80) NOT NULL UNIQUE, |
1260 |
`spec` varchar(80) NOT NULL UNIQUE, |
| 1261 |
`name` varchar(80) NOT NULL, |
1261 |
`name` varchar(80) NOT NULL, |
| 1262 |
PRIMARY KEY (`id`) |
1262 |
PRIMARY KEY (`id`) |
| 1263 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1263 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1264 |
|
1264 |
|
| 1265 |
-- |
1265 |
-- |
| 1266 |
-- Table structure for table `oai_sets_descriptions` |
1266 |
-- Table structure for table `oai_sets_descriptions` |
|
Lines 1271-1277
CREATE TABLE `oai_sets_descriptions` (
Link Here
|
| 1271 |
`set_id` int(11) NOT NULL, |
1271 |
`set_id` int(11) NOT NULL, |
| 1272 |
`description` varchar(255) NOT NULL, |
1272 |
`description` varchar(255) NOT NULL, |
| 1273 |
CONSTRAINT `oai_sets_descriptions_ibfk_1` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
1273 |
CONSTRAINT `oai_sets_descriptions_ibfk_1` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1274 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1274 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1275 |
|
1275 |
|
| 1276 |
-- |
1276 |
-- |
| 1277 |
-- Table structure for table `oai_sets_mappings` |
1277 |
-- Table structure for table `oai_sets_mappings` |
|
Lines 1285-1291
CREATE TABLE `oai_sets_mappings` (
Link Here
|
| 1285 |
`operator` varchar(8) NOT NULL default 'equal', |
1285 |
`operator` varchar(8) NOT NULL default 'equal', |
| 1286 |
`marcvalue` varchar(80) NOT NULL, |
1286 |
`marcvalue` varchar(80) NOT NULL, |
| 1287 |
CONSTRAINT `oai_sets_mappings_ibfk_1` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
1287 |
CONSTRAINT `oai_sets_mappings_ibfk_1` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1288 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1288 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1289 |
|
1289 |
|
| 1290 |
-- |
1290 |
-- |
| 1291 |
-- Table structure for table `oai_sets_biblios` |
1291 |
-- Table structure for table `oai_sets_biblios` |
|
Lines 1297-1303
CREATE TABLE `oai_sets_biblios` (
Link Here
|
| 1297 |
`set_id` int(11) NOT NULL, |
1297 |
`set_id` int(11) NOT NULL, |
| 1298 |
PRIMARY KEY (`biblionumber`, `set_id`), |
1298 |
PRIMARY KEY (`biblionumber`, `set_id`), |
| 1299 |
CONSTRAINT `oai_sets_biblios_ibfk_2` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
1299 |
CONSTRAINT `oai_sets_biblios_ibfk_2` FOREIGN KEY (`set_id`) REFERENCES `oai_sets` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1300 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1300 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1301 |
|
1301 |
|
| 1302 |
-- |
1302 |
-- |
| 1303 |
-- Table structure for table `overduerules` |
1303 |
-- Table structure for table `overduerules` |
|
Lines 1319-1325
CREATE TABLE `overduerules` ( -- overdue notice status and triggers
Link Here
|
| 1319 |
`debarred3` int(1) default 0, -- is the patron restricted when the third notice is sent (1 for yes, 0 for no) |
1319 |
`debarred3` int(1) default 0, -- is the patron restricted when the third notice is sent (1 for yes, 0 for no) |
| 1320 |
PRIMARY KEY (`overduerules_id`), |
1320 |
PRIMARY KEY (`overduerules_id`), |
| 1321 |
UNIQUE KEY `overduerules_branch_cat` (`branchcode`,`categorycode`) |
1321 |
UNIQUE KEY `overduerules_branch_cat` (`branchcode`,`categorycode`) |
| 1322 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1322 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1323 |
|
1323 |
|
| 1324 |
-- Table structure for table `pending_offline_operations` |
1324 |
-- Table structure for table `pending_offline_operations` |
| 1325 |
-- |
1325 |
-- |
|
Lines 1337-1343
CREATE TABLE pending_offline_operations (
Link Here
|
| 1337 |
cardnumber varchar(32) DEFAULT NULL, |
1337 |
cardnumber varchar(32) DEFAULT NULL, |
| 1338 |
amount decimal(28,6) DEFAULT NULL, |
1338 |
amount decimal(28,6) DEFAULT NULL, |
| 1339 |
PRIMARY KEY (operationid) |
1339 |
PRIMARY KEY (operationid) |
| 1340 |
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1340 |
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1341 |
|
1341 |
|
| 1342 |
|
1342 |
|
| 1343 |
-- |
1343 |
-- |
|
Lines 1350-1356
CREATE TABLE `printers` (
Link Here
|
| 1350 |
`printqueue` varchar(20) default NULL, |
1350 |
`printqueue` varchar(20) default NULL, |
| 1351 |
`printtype` varchar(20) default NULL, |
1351 |
`printtype` varchar(20) default NULL, |
| 1352 |
PRIMARY KEY (`printername`) |
1352 |
PRIMARY KEY (`printername`) |
| 1353 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1353 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1354 |
|
1354 |
|
| 1355 |
-- |
1355 |
-- |
| 1356 |
-- Table structure for table `printers_profile` |
1356 |
-- Table structure for table `printers_profile` |
|
Lines 1370-1376
CREATE TABLE `printers_profile` (
Link Here
|
| 1370 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
1370 |
`creator` char(15) NOT NULL DEFAULT 'Labels', |
| 1371 |
PRIMARY KEY (`profile_id`), |
1371 |
PRIMARY KEY (`profile_id`), |
| 1372 |
UNIQUE KEY `printername` (`printer_name`,`template_id`,`paper_bin`,`creator`) |
1372 |
UNIQUE KEY `printername` (`printer_name`,`template_id`,`paper_bin`,`creator`) |
| 1373 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1373 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1374 |
|
1374 |
|
| 1375 |
-- |
1375 |
-- |
| 1376 |
-- Table structure for table `repeatable_holidays` |
1376 |
-- Table structure for table `repeatable_holidays` |
|
Lines 1386-1392
CREATE TABLE `repeatable_holidays` ( -- information for the days the library is
Link Here
|
| 1386 |
`title` varchar(50) NOT NULL default '', -- title of this closing |
1386 |
`title` varchar(50) NOT NULL default '', -- title of this closing |
| 1387 |
`description` text NOT NULL, -- description for this closing |
1387 |
`description` text NOT NULL, -- description for this closing |
| 1388 |
PRIMARY KEY (`id`) |
1388 |
PRIMARY KEY (`id`) |
| 1389 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1389 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1390 |
|
1390 |
|
| 1391 |
-- |
1391 |
-- |
| 1392 |
-- Table structure for table `reports_dictionary` |
1392 |
-- Table structure for table `reports_dictionary` |
|
Lines 1403-1409
CREATE TABLE reports_dictionary ( -- definitions (or snippets of SQL) stored for
Link Here
|
| 1403 |
report_area varchar(6) DEFAULT NULL, -- Koha module this definition is for Circulation, Catalog, Patrons, Acquistions, Accounts) |
1403 |
report_area varchar(6) DEFAULT NULL, -- Koha module this definition is for Circulation, Catalog, Patrons, Acquistions, Accounts) |
| 1404 |
PRIMARY KEY (id), |
1404 |
PRIMARY KEY (id), |
| 1405 |
KEY dictionary_area_idx (report_area) |
1405 |
KEY dictionary_area_idx (report_area) |
| 1406 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1406 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1407 |
|
1407 |
|
| 1408 |
-- |
1408 |
-- |
| 1409 |
-- Table structure for table `saved_sql` |
1409 |
-- Table structure for table `saved_sql` |
|
Lines 1428-1434
CREATE TABLE saved_sql ( -- saved sql reports
Link Here
|
| 1428 |
PRIMARY KEY (`id`), |
1428 |
PRIMARY KEY (`id`), |
| 1429 |
KEY sql_area_group_idx (report_group, report_subgroup), |
1429 |
KEY sql_area_group_idx (report_group, report_subgroup), |
| 1430 |
KEY boridx (`borrowernumber`) |
1430 |
KEY boridx (`borrowernumber`) |
| 1431 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1431 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1432 |
|
1432 |
|
| 1433 |
|
1433 |
|
| 1434 |
-- |
1434 |
-- |
|
Lines 1442-1448
CREATE TABLE saved_reports (
Link Here
|
| 1442 |
`report` longtext, |
1442 |
`report` longtext, |
| 1443 |
`date_run` datetime default NULL, |
1443 |
`date_run` datetime default NULL, |
| 1444 |
PRIMARY KEY (`id`) |
1444 |
PRIMARY KEY (`id`) |
| 1445 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1445 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1446 |
|
1446 |
|
| 1447 |
-- |
1447 |
-- |
| 1448 |
-- Table structure for table 'search_field' |
1448 |
-- Table structure for table 'search_field' |
|
Lines 1455-1462
CREATE TABLE `search_field` (
Link Here
|
| 1455 |
`label` varchar(255) NOT NULL COMMENT 'the human readable name of the field, for display', |
1455 |
`label` varchar(255) NOT NULL COMMENT 'the human readable name of the field, for display', |
| 1456 |
`type` ENUM('', 'string', 'date', 'number', 'boolean', 'sum') NOT NULL COMMENT 'what type of data this holds, relevant when storing it in the search engine', |
1456 |
`type` ENUM('', 'string', 'date', 'number', 'boolean', 'sum') NOT NULL COMMENT 'what type of data this holds, relevant when storing it in the search engine', |
| 1457 |
PRIMARY KEY (`id`), |
1457 |
PRIMARY KEY (`id`), |
| 1458 |
UNIQUE KEY (`name`) |
1458 |
UNIQUE KEY (`name` (191) ) |
| 1459 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1459 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1460 |
|
1460 |
|
| 1461 |
-- |
1461 |
-- |
| 1462 |
-- Table structure for table `search_history` |
1462 |
-- Table structure for table `search_history` |
|
Lines 1475-1481
CREATE TABLE IF NOT EXISTS `search_history` ( -- patron's opac search history
Link Here
|
| 1475 |
KEY `userid` (`userid`), |
1475 |
KEY `userid` (`userid`), |
| 1476 |
KEY `sessionid` (`sessionid`), |
1476 |
KEY `sessionid` (`sessionid`), |
| 1477 |
PRIMARY KEY (`id`) |
1477 |
PRIMARY KEY (`id`) |
| 1478 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='Opac search history results'; |
1478 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='Opac search history results'; |
| 1479 |
|
1479 |
|
| 1480 |
-- |
1480 |
-- |
| 1481 |
-- Table structure for table 'search_marc_map' |
1481 |
-- Table structure for table 'search_marc_map' |
|
Lines 1488-1496
CREATE TABLE `search_marc_map` (
Link Here
|
| 1488 |
marc_type ENUM('marc21', 'unimarc', 'normarc') NOT NULL COMMENT 'what MARC type this map is for', |
1488 |
marc_type ENUM('marc21', 'unimarc', 'normarc') NOT NULL COMMENT 'what MARC type this map is for', |
| 1489 |
marc_field VARCHAR(255) NOT NULL COMMENT 'the MARC specifier for this field', |
1489 |
marc_field VARCHAR(255) NOT NULL COMMENT 'the MARC specifier for this field', |
| 1490 |
PRIMARY KEY(`id`), |
1490 |
PRIMARY KEY(`id`), |
| 1491 |
UNIQUE key(index_name, marc_field, marc_type), |
1491 |
UNIQUE key(index_name, marc_field(191), marc_type), |
| 1492 |
INDEX (`index_name`) |
1492 |
INDEX (`index_name`) |
| 1493 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1493 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1494 |
|
1494 |
|
| 1495 |
-- |
1495 |
-- |
| 1496 |
-- Table structure for table 'search_marc_to_field' |
1496 |
-- Table structure for table 'search_marc_to_field' |
|
Lines 1506-1512
CREATE TABLE `search_marc_to_field` (
Link Here
|
| 1506 |
PRIMARY KEY(search_marc_map_id, search_field_id), |
1506 |
PRIMARY KEY(search_marc_map_id, search_field_id), |
| 1507 |
FOREIGN KEY(search_marc_map_id) REFERENCES search_marc_map(id) ON DELETE CASCADE ON UPDATE CASCADE, |
1507 |
FOREIGN KEY(search_marc_map_id) REFERENCES search_marc_map(id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1508 |
FOREIGN KEY(search_field_id) REFERENCES search_field(id) ON DELETE CASCADE ON UPDATE CASCADE |
1508 |
FOREIGN KEY(search_field_id) REFERENCES search_field(id) ON DELETE CASCADE ON UPDATE CASCADE |
| 1509 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1509 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1510 |
|
1510 |
|
| 1511 |
-- |
1511 |
-- |
| 1512 |
-- Table structure for table `serial` |
1512 |
-- Table structure for table `serial` |
|
Lines 1530-1536
CREATE TABLE `serial` ( -- issues related to subscriptions
Link Here
|
| 1530 |
claims_count int(11) default 0, -- number of claims made related to this issue |
1530 |
claims_count int(11) default 0, -- number of claims made related to this issue |
| 1531 |
`routingnotes` text, -- notes from the routing list |
1531 |
`routingnotes` text, -- notes from the routing list |
| 1532 |
PRIMARY KEY (`serialid`) |
1532 |
PRIMARY KEY (`serialid`) |
| 1533 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1533 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1534 |
|
1534 |
|
| 1535 |
-- |
1535 |
-- |
| 1536 |
-- Table structure for table `sessions` |
1536 |
-- Table structure for table `sessions` |
|
Lines 1541-1547
CREATE TABLE sessions (
Link Here
|
| 1541 |
`id` varchar(32) NOT NULL, |
1541 |
`id` varchar(32) NOT NULL, |
| 1542 |
`a_session` mediumtext NOT NULL, |
1542 |
`a_session` mediumtext NOT NULL, |
| 1543 |
PRIMARY KEY (`id`) |
1543 |
PRIMARY KEY (`id`) |
| 1544 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1544 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1545 |
|
1545 |
|
| 1546 |
-- |
1546 |
-- |
| 1547 |
-- Table structure for table `sms_providers` |
1547 |
-- Table structure for table `sms_providers` |
|
Lines 1553-1560
CREATE TABLE `sms_providers` (
Link Here
|
| 1553 |
`name` varchar(255) NOT NULL, |
1553 |
`name` varchar(255) NOT NULL, |
| 1554 |
`domain` varchar(255) NOT NULL, |
1554 |
`domain` varchar(255) NOT NULL, |
| 1555 |
PRIMARY KEY (`id`), |
1555 |
PRIMARY KEY (`id`), |
| 1556 |
UNIQUE KEY `name` (`name`) |
1556 |
UNIQUE KEY `name` (`name` (191)) |
| 1557 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1557 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1558 |
|
1558 |
|
| 1559 |
-- |
1559 |
-- |
| 1560 |
-- Table structure for table `borrowers` |
1560 |
-- Table structure for table `borrowers` |
|
Lines 1642-1655
CREATE TABLE `borrowers` ( -- this table includes information about your patrons
Link Here
|
| 1642 |
KEY `branchcode` (`branchcode`), |
1642 |
KEY `branchcode` (`branchcode`), |
| 1643 |
UNIQUE KEY `userid` (`userid`), |
1643 |
UNIQUE KEY `userid` (`userid`), |
| 1644 |
KEY `guarantorid` (`guarantorid`), |
1644 |
KEY `guarantorid` (`guarantorid`), |
| 1645 |
KEY `surname_idx` (`surname`(255)), |
1645 |
KEY `surname_idx` (`surname` (191)), |
| 1646 |
KEY `firstname_idx` (`firstname`(255)), |
1646 |
KEY `firstname_idx` (`firstname` (191)), |
| 1647 |
KEY `othernames_idx` (`othernames`(255)), |
1647 |
KEY `othernames_idx` (`othernames` (191)), |
| 1648 |
KEY `sms_provider_id` (`sms_provider_id`), |
1648 |
KEY `sms_provider_id` (`sms_provider_id`), |
| 1649 |
CONSTRAINT `borrowers_ibfk_1` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`), |
1649 |
CONSTRAINT `borrowers_ibfk_1` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`), |
| 1650 |
CONSTRAINT `borrowers_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`), |
1650 |
CONSTRAINT `borrowers_ibfk_2` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`), |
| 1651 |
CONSTRAINT `borrowers_ibfk_3` FOREIGN KEY (`sms_provider_id`) REFERENCES `sms_providers` (`id`) ON UPDATE CASCADE ON DELETE SET NULL |
1651 |
CONSTRAINT `borrowers_ibfk_3` FOREIGN KEY (`sms_provider_id`) REFERENCES `sms_providers` (`id`) ON UPDATE CASCADE ON DELETE SET NULL |
| 1652 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1652 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1653 |
|
1653 |
|
| 1654 |
-- |
1654 |
-- |
| 1655 |
-- Table structure for table `borrower_attributes` |
1655 |
-- Table structure for table `borrower_attributes` |
|
Lines 1662-1673
CREATE TABLE `borrower_attributes` ( -- values of custom patron fields known as
Link Here
|
| 1662 |
`code` varchar(10) NOT NULL, -- foreign key from the borrower_attribute_types table, defines which custom field this value was entered for |
1662 |
`code` varchar(10) NOT NULL, -- foreign key from the borrower_attribute_types table, defines which custom field this value was entered for |
| 1663 |
`attribute` varchar(255) default NULL, -- custom patron field value |
1663 |
`attribute` varchar(255) default NULL, -- custom patron field value |
| 1664 |
KEY `borrowernumber` (`borrowernumber`), |
1664 |
KEY `borrowernumber` (`borrowernumber`), |
| 1665 |
KEY `code_attribute` (`code`, `attribute`), |
1665 |
KEY `code_attribute` (`code`, `attribute` (191)), |
| 1666 |
CONSTRAINT `borrower_attributes_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) |
1666 |
CONSTRAINT `borrower_attributes_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) |
| 1667 |
ON DELETE CASCADE ON UPDATE CASCADE, |
1667 |
ON DELETE CASCADE ON UPDATE CASCADE, |
| 1668 |
CONSTRAINT `borrower_attributes_ibfk_2` FOREIGN KEY (`code`) REFERENCES `borrower_attribute_types` (`code`) |
1668 |
CONSTRAINT `borrower_attributes_ibfk_2` FOREIGN KEY (`code`) REFERENCES `borrower_attribute_types` (`code`) |
| 1669 |
ON DELETE CASCADE ON UPDATE CASCADE |
1669 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 1670 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1670 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1671 |
|
1671 |
|
| 1672 |
-- |
1672 |
-- |
| 1673 |
-- Table structure for table `borrower_debarments` |
1673 |
-- Table structure for table `borrower_debarments` |
|
Lines 1687-1693
CREATE TABLE borrower_debarments ( -- tracks restrictions on the patron's record
Link Here
|
| 1687 |
KEY borrowernumber (borrowernumber), |
1687 |
KEY borrowernumber (borrowernumber), |
| 1688 |
CONSTRAINT `borrower_debarments_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) |
1688 |
CONSTRAINT `borrower_debarments_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) |
| 1689 |
ON DELETE CASCADE ON UPDATE CASCADE |
1689 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 1690 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1690 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1691 |
|
1691 |
|
| 1692 |
-- |
1692 |
-- |
| 1693 |
-- Table structure for table borrower_sync |
1693 |
-- Table structure for table borrower_sync |
|
Lines 1705-1711
CREATE TABLE borrower_sync (
Link Here
|
| 1705 |
PRIMARY KEY (borrowersyncid), |
1705 |
PRIMARY KEY (borrowersyncid), |
| 1706 |
KEY borrowernumber (borrowernumber), |
1706 |
KEY borrowernumber (borrowernumber), |
| 1707 |
CONSTRAINT borrower_sync_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
1707 |
CONSTRAINT borrower_sync_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 1708 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1708 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1709 |
|
1709 |
|
| 1710 |
-- |
1710 |
-- |
| 1711 |
-- Table structure for table `issues` |
1711 |
-- Table structure for table `issues` |
|
Lines 1722-1728
CREATE TABLE `issues` ( -- information related to check outs or issues
Link Here
|
| 1722 |
`lastreneweddate` datetime default NULL, -- date the item was last renewed |
1722 |
`lastreneweddate` datetime default NULL, -- date the item was last renewed |
| 1723 |
`renewals` tinyint(4) default NULL, -- lists the number of times the item was renewed |
1723 |
`renewals` tinyint(4) default NULL, -- lists the number of times the item was renewed |
| 1724 |
`auto_renew` BOOLEAN default FALSE, -- automatic renewal |
1724 |
`auto_renew` BOOLEAN default FALSE, -- automatic renewal |
| 1725 |
`auto_renew_error` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, -- automatic renewal error |
1725 |
`auto_renew_error` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT NULL, -- automatic renewal error |
| 1726 |
`timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP, -- the date and time this record was last touched |
1726 |
`timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP, -- the date and time this record was last touched |
| 1727 |
`issuedate` datetime default NULL, -- date the item was checked out or issued |
1727 |
`issuedate` datetime default NULL, -- date the item was checked out or issued |
| 1728 |
`onsite_checkout` int(1) NOT NULL default 0, -- in house use flag |
1728 |
`onsite_checkout` int(1) NOT NULL default 0, -- in house use flag |
|
Lines 1736-1742
CREATE TABLE `issues` ( -- information related to check outs or issues
Link Here
|
| 1736 |
KEY `bordate` (`borrowernumber`,`timestamp`), |
1736 |
KEY `bordate` (`borrowernumber`,`timestamp`), |
| 1737 |
CONSTRAINT `issues_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE RESTRICT ON UPDATE CASCADE, |
1737 |
CONSTRAINT `issues_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE RESTRICT ON UPDATE CASCADE, |
| 1738 |
CONSTRAINT `issues_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE RESTRICT ON UPDATE CASCADE |
1738 |
CONSTRAINT `issues_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE RESTRICT ON UPDATE CASCADE |
| 1739 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1739 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1740 |
|
1740 |
|
| 1741 |
-- |
1741 |
-- |
| 1742 |
-- Table structure for table `old_issues` |
1742 |
-- Table structure for table `old_issues` |
|
Lines 1753-1759
CREATE TABLE `old_issues` ( -- lists items that were checked out and have been r
Link Here
|
| 1753 |
`lastreneweddate` datetime default NULL, -- date the item was last renewed |
1753 |
`lastreneweddate` datetime default NULL, -- date the item was last renewed |
| 1754 |
`renewals` tinyint(4) default NULL, -- lists the number of times the item was renewed |
1754 |
`renewals` tinyint(4) default NULL, -- lists the number of times the item was renewed |
| 1755 |
`auto_renew` BOOLEAN default FALSE, -- automatic renewal |
1755 |
`auto_renew` BOOLEAN default FALSE, -- automatic renewal |
| 1756 |
`auto_renew_error` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, -- automatic renewal error |
1756 |
`auto_renew_error` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT NULL, -- automatic renewal error |
| 1757 |
`timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP, -- the date and time this record was last touched |
1757 |
`timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP, -- the date and time this record was last touched |
| 1758 |
`issuedate` datetime default NULL, -- date the item was checked out or issued |
1758 |
`issuedate` datetime default NULL, -- date the item was checked out or issued |
| 1759 |
`onsite_checkout` int(1) NOT NULL default 0, -- in house use flag |
1759 |
`onsite_checkout` int(1) NOT NULL default 0, -- in house use flag |
|
Lines 1768-1774
CREATE TABLE `old_issues` ( -- lists items that were checked out and have been r
Link Here
|
| 1768 |
ON DELETE SET NULL ON UPDATE SET NULL, |
1768 |
ON DELETE SET NULL ON UPDATE SET NULL, |
| 1769 |
CONSTRAINT `old_issues_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) |
1769 |
CONSTRAINT `old_issues_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) |
| 1770 |
ON DELETE SET NULL ON UPDATE SET NULL |
1770 |
ON DELETE SET NULL ON UPDATE SET NULL |
| 1771 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1771 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1772 |
|
1772 |
|
| 1773 |
-- |
1773 |
-- |
| 1774 |
-- Table structure for table `items_last_borrower` |
1774 |
-- Table structure for table `items_last_borrower` |
|
Lines 1784-1790
CREATE TABLE IF NOT EXISTS `items_last_borrower` (
Link Here
|
| 1784 |
KEY `borrowernumber` (`borrowernumber`), |
1784 |
KEY `borrowernumber` (`borrowernumber`), |
| 1785 |
CONSTRAINT `items_last_borrower_ibfk_2` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
1785 |
CONSTRAINT `items_last_borrower_ibfk_2` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1786 |
CONSTRAINT `items_last_borrower_ibfk_1` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
1786 |
CONSTRAINT `items_last_borrower_ibfk_1` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1787 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1787 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1788 |
|
1788 |
|
| 1789 |
-- |
1789 |
-- |
| 1790 |
-- Table structure for table `creator_batches` |
1790 |
-- Table structure for table `creator_batches` |
|
Lines 1808-1814
CREATE TABLE `creator_batches` (
Link Here
|
| 1808 |
CONSTRAINT `creator_batches_ibfk_1` FOREIGN KEY (`borrower_number`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
1808 |
CONSTRAINT `creator_batches_ibfk_1` FOREIGN KEY (`borrower_number`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1809 |
CONSTRAINT `creator_batches_ibfk_2` FOREIGN KEY (`branch_code`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE, |
1809 |
CONSTRAINT `creator_batches_ibfk_2` FOREIGN KEY (`branch_code`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE, |
| 1810 |
CONSTRAINT `creator_batches_ibfk_3` FOREIGN KEY (`item_number`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE |
1810 |
CONSTRAINT `creator_batches_ibfk_3` FOREIGN KEY (`item_number`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE |
| 1811 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1811 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1812 |
|
1812 |
|
| 1813 |
-- |
1813 |
-- |
| 1814 |
-- Table structure for table `opac_news` |
1814 |
-- Table structure for table `opac_news` |
|
Lines 1829-1835
CREATE TABLE `opac_news` ( -- data from the news tool
Link Here
|
| 1829 |
CONSTRAINT `borrowernumber_fk` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
1829 |
CONSTRAINT `borrowernumber_fk` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
| 1830 |
CONSTRAINT opac_news_branchcode_ibfk FOREIGN KEY (branchcode) REFERENCES branches (branchcode) |
1830 |
CONSTRAINT opac_news_branchcode_ibfk FOREIGN KEY (branchcode) REFERENCES branches (branchcode) |
| 1831 |
ON DELETE CASCADE ON UPDATE CASCADE |
1831 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 1832 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1832 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1833 |
|
1833 |
|
| 1834 |
-- |
1834 |
-- |
| 1835 |
-- Table structure for table `patronimage` |
1835 |
-- Table structure for table `patronimage` |
|
Lines 1842-1848
CREATE TABLE `patronimage` ( -- information related to patron images
Link Here
|
| 1842 |
`imagefile` mediumblob NOT NULL, -- the image |
1842 |
`imagefile` mediumblob NOT NULL, -- the image |
| 1843 |
PRIMARY KEY (`borrowernumber`), |
1843 |
PRIMARY KEY (`borrowernumber`), |
| 1844 |
CONSTRAINT `patronimage_fk1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE |
1844 |
CONSTRAINT `patronimage_fk1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1845 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1845 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1846 |
|
1846 |
|
| 1847 |
-- |
1847 |
-- |
| 1848 |
-- Table structure for table `reserves` |
1848 |
-- Table structure for table `reserves` |
|
Lines 1881-1887
CREATE TABLE `reserves` ( -- information related to holds/reserves in Koha
Link Here
|
| 1881 |
CONSTRAINT `reserves_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
1881 |
CONSTRAINT `reserves_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1882 |
CONSTRAINT `reserves_ibfk_4` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
1882 |
CONSTRAINT `reserves_ibfk_4` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 1883 |
CONSTRAINT `reserves_ibfk_5` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE |
1883 |
CONSTRAINT `reserves_ibfk_5` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1884 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1884 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1885 |
|
1885 |
|
| 1886 |
-- |
1886 |
-- |
| 1887 |
-- Table structure for table `old_reserves` |
1887 |
-- Table structure for table `old_reserves` |
|
Lines 1922-1928
CREATE TABLE `old_reserves` ( -- this table holds all holds/reserves that have b
Link Here
|
| 1922 |
ON DELETE SET NULL ON UPDATE SET NULL, |
1922 |
ON DELETE SET NULL ON UPDATE SET NULL, |
| 1923 |
CONSTRAINT `old_reserves_ibfk_4` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) |
1923 |
CONSTRAINT `old_reserves_ibfk_4` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) |
| 1924 |
ON DELETE SET NULL ON UPDATE SET NULL |
1924 |
ON DELETE SET NULL ON UPDATE SET NULL |
| 1925 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1925 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1926 |
|
1926 |
|
| 1927 |
-- |
1927 |
-- |
| 1928 |
-- Table structure for table `reviews` |
1928 |
-- Table structure for table `reviews` |
|
Lines 1939-1945
CREATE TABLE `reviews` ( -- patron opac comments
Link Here
|
| 1939 |
PRIMARY KEY (`reviewid`), |
1939 |
PRIMARY KEY (`reviewid`), |
| 1940 |
CONSTRAINT `reviews_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
1940 |
CONSTRAINT `reviews_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
| 1941 |
CONSTRAINT `reviews_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
1941 |
CONSTRAINT `reviews_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 1942 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1942 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1943 |
|
1943 |
|
| 1944 |
-- |
1944 |
-- |
| 1945 |
-- Table structure for table `special_holidays` |
1945 |
-- Table structure for table `special_holidays` |
|
Lines 1956-1962
CREATE TABLE `special_holidays` ( -- non repeatable holidays/library closings
Link Here
|
| 1956 |
`title` varchar(50) NOT NULL default '', -- title for this closing |
1956 |
`title` varchar(50) NOT NULL default '', -- title for this closing |
| 1957 |
`description` text NOT NULL, -- description of this closing |
1957 |
`description` text NOT NULL, -- description of this closing |
| 1958 |
PRIMARY KEY (`id`) |
1958 |
PRIMARY KEY (`id`) |
| 1959 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1959 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1960 |
|
1960 |
|
| 1961 |
-- |
1961 |
-- |
| 1962 |
-- Table structure for table `statistics` |
1962 |
-- Table structure for table `statistics` |
|
Lines 1987-1993
CREATE TABLE `statistics` ( -- information related to transactions (circulation
Link Here
|
| 1987 |
KEY `borrowernumber_idx` (`borrowernumber`), |
1987 |
KEY `borrowernumber_idx` (`borrowernumber`), |
| 1988 |
KEY `associatedborrower_idx` (`associatedborrower`), |
1988 |
KEY `associatedborrower_idx` (`associatedborrower`), |
| 1989 |
KEY `ccode_idx` (`ccode`) |
1989 |
KEY `ccode_idx` (`ccode`) |
| 1990 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
1990 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 1991 |
|
1991 |
|
| 1992 |
-- |
1992 |
-- |
| 1993 |
-- Table structure for table subscription_frequencies |
1993 |
-- Table structure for table subscription_frequencies |
|
Lines 2002-2008
CREATE TABLE subscription_frequencies (
Link Here
|
| 2002 |
unitsperissue INTEGER NOT NULL DEFAULT '1', |
2002 |
unitsperissue INTEGER NOT NULL DEFAULT '1', |
| 2003 |
issuesperunit INTEGER NOT NULL DEFAULT '1', |
2003 |
issuesperunit INTEGER NOT NULL DEFAULT '1', |
| 2004 |
PRIMARY KEY (id) |
2004 |
PRIMARY KEY (id) |
| 2005 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2005 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2006 |
|
2006 |
|
| 2007 |
-- |
2007 |
-- |
| 2008 |
-- Table structure for table subscription_numberpatterns |
2008 |
-- Table structure for table subscription_numberpatterns |
|
Lines 2034-2040
CREATE TABLE subscription_numberpatterns (
Link Here
|
| 2034 |
setto3 INTEGER DEFAULT NULL, |
2034 |
setto3 INTEGER DEFAULT NULL, |
| 2035 |
numbering3 VARCHAR(255) DEFAULT NULL, |
2035 |
numbering3 VARCHAR(255) DEFAULT NULL, |
| 2036 |
PRIMARY KEY (id) |
2036 |
PRIMARY KEY (id) |
| 2037 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2037 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2038 |
|
2038 |
|
| 2039 |
-- |
2039 |
-- |
| 2040 |
-- Table structure for table `subscription` |
2040 |
-- Table structure for table `subscription` |
|
Lines 2087-2093
CREATE TABLE `subscription` ( -- information related to the subscription
Link Here
|
| 2087 |
PRIMARY KEY (`subscriptionid`), |
2087 |
PRIMARY KEY (`subscriptionid`), |
| 2088 |
CONSTRAINT subscription_ibfk_1 FOREIGN KEY (periodicity) REFERENCES subscription_frequencies (id) ON DELETE SET NULL ON UPDATE CASCADE, |
2088 |
CONSTRAINT subscription_ibfk_1 FOREIGN KEY (periodicity) REFERENCES subscription_frequencies (id) ON DELETE SET NULL ON UPDATE CASCADE, |
| 2089 |
CONSTRAINT subscription_ibfk_2 FOREIGN KEY (numberpattern) REFERENCES subscription_numberpatterns (id) ON DELETE SET NULL ON UPDATE CASCADE |
2089 |
CONSTRAINT subscription_ibfk_2 FOREIGN KEY (numberpattern) REFERENCES subscription_numberpatterns (id) ON DELETE SET NULL ON UPDATE CASCADE |
| 2090 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2090 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2091 |
|
2091 |
|
| 2092 |
-- |
2092 |
-- |
| 2093 |
-- Table structure for table `subscriptionhistory` |
2093 |
-- Table structure for table `subscriptionhistory` |
|
Lines 2105-2111
CREATE TABLE `subscriptionhistory` (
Link Here
|
| 2105 |
`librariannote` varchar(150) NOT NULL default '', |
2105 |
`librariannote` varchar(150) NOT NULL default '', |
| 2106 |
PRIMARY KEY (`subscriptionid`), |
2106 |
PRIMARY KEY (`subscriptionid`), |
| 2107 |
KEY `biblionumber` (`biblionumber`) |
2107 |
KEY `biblionumber` (`biblionumber`) |
| 2108 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2108 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2109 |
|
2109 |
|
| 2110 |
-- |
2110 |
-- |
| 2111 |
-- Table structure for table `subscriptionroutinglist` |
2111 |
-- Table structure for table `subscriptionroutinglist` |
|
Lines 2123-2129
CREATE TABLE `subscriptionroutinglist` ( -- information related to the routing l
Link Here
|
| 2123 |
ON DELETE CASCADE ON UPDATE CASCADE, |
2123 |
ON DELETE CASCADE ON UPDATE CASCADE, |
| 2124 |
CONSTRAINT `subscriptionroutinglist_ibfk_2` FOREIGN KEY (`subscriptionid`) REFERENCES `subscription` (`subscriptionid`) |
2124 |
CONSTRAINT `subscriptionroutinglist_ibfk_2` FOREIGN KEY (`subscriptionid`) REFERENCES `subscription` (`subscriptionid`) |
| 2125 |
ON DELETE CASCADE ON UPDATE CASCADE |
2125 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 2126 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2126 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2127 |
|
2127 |
|
| 2128 |
-- |
2128 |
-- |
| 2129 |
-- Table structure for table `systempreferences` |
2129 |
-- Table structure for table `systempreferences` |
|
Lines 2137-2143
CREATE TABLE `systempreferences` ( -- global system preferences
Link Here
|
| 2137 |
`explanation` text, -- descriptive text for the system preference |
2137 |
`explanation` text, -- descriptive text for the system preference |
| 2138 |
`type` varchar(20) default NULL, -- type of question this preference asks (multiple choice, plain text, yes or no, etc) |
2138 |
`type` varchar(20) default NULL, -- type of question this preference asks (multiple choice, plain text, yes or no, etc) |
| 2139 |
PRIMARY KEY (`variable`) |
2139 |
PRIMARY KEY (`variable`) |
| 2140 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2140 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2141 |
|
2141 |
|
| 2142 |
-- |
2142 |
-- |
| 2143 |
-- Table structure for table `tags` |
2143 |
-- Table structure for table `tags` |
|
Lines 2147-2154
DROP TABLE IF EXISTS `tags`;
Link Here
|
| 2147 |
CREATE TABLE `tags` ( |
2147 |
CREATE TABLE `tags` ( |
| 2148 |
`entry` varchar(255) NOT NULL default '', |
2148 |
`entry` varchar(255) NOT NULL default '', |
| 2149 |
`weight` bigint(20) NOT NULL default 0, |
2149 |
`weight` bigint(20) NOT NULL default 0, |
| 2150 |
PRIMARY KEY (`entry`) |
2150 |
PRIMARY KEY (`entry` (191)) |
| 2151 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2151 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2152 |
|
2152 |
|
| 2153 |
-- |
2153 |
-- |
| 2154 |
-- Table structure for table `tags_all` |
2154 |
-- Table structure for table `tags_all` |
|
Lines 2169-2175
CREATE TABLE `tags_all` ( -- all of the tags
Link Here
|
| 2169 |
REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
2169 |
REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
| 2170 |
CONSTRAINT `tags_biblionumber_fk_1` FOREIGN KEY (`biblionumber`) |
2170 |
CONSTRAINT `tags_biblionumber_fk_1` FOREIGN KEY (`biblionumber`) |
| 2171 |
REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
2171 |
REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2172 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2172 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2173 |
|
2173 |
|
| 2174 |
-- |
2174 |
-- |
| 2175 |
-- Table structure for table `tags_approval` |
2175 |
-- Table structure for table `tags_approval` |
|
Lines 2177-2183
CREATE TABLE `tags_all` ( -- all of the tags
Link Here
|
| 2177 |
|
2177 |
|
| 2178 |
DROP TABLE IF EXISTS `tags_approval`; |
2178 |
DROP TABLE IF EXISTS `tags_approval`; |
| 2179 |
CREATE TABLE `tags_approval` ( -- approved tags |
2179 |
CREATE TABLE `tags_approval` ( -- approved tags |
| 2180 |
`term` varchar(255) NOT NULL, -- the tag |
2180 |
`term` varchar(191) NOT NULL, -- the tag |
| 2181 |
`approved` int(1) NOT NULL default '0', -- whether the tag is approved or not (1=yes, 0=pending, -1=rejected) |
2181 |
`approved` int(1) NOT NULL default '0', -- whether the tag is approved or not (1=yes, 0=pending, -1=rejected) |
| 2182 |
`date_approved` datetime default NULL, -- the date this tag was approved |
2182 |
`date_approved` datetime default NULL, -- the date this tag was approved |
| 2183 |
`approved_by` int(11) default NULL, -- the librarian who approved the tag (borrowers.borrowernumber) |
2183 |
`approved_by` int(11) default NULL, -- the librarian who approved the tag (borrowers.borrowernumber) |
|
Lines 2186-2192
CREATE TABLE `tags_approval` ( -- approved tags
Link Here
|
| 2186 |
KEY `tags_approval_borrowers_fk_1` (`approved_by`), |
2186 |
KEY `tags_approval_borrowers_fk_1` (`approved_by`), |
| 2187 |
CONSTRAINT `tags_approval_borrowers_fk_1` FOREIGN KEY (`approved_by`) |
2187 |
CONSTRAINT `tags_approval_borrowers_fk_1` FOREIGN KEY (`approved_by`) |
| 2188 |
REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE |
2188 |
REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE CASCADE |
| 2189 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2189 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2190 |
|
2190 |
|
| 2191 |
-- |
2191 |
-- |
| 2192 |
-- Table structure for table `tags_index` |
2192 |
-- Table structure for table `tags_index` |
|
Lines 2194-2200
CREATE TABLE `tags_approval` ( -- approved tags
Link Here
|
| 2194 |
|
2194 |
|
| 2195 |
DROP TABLE IF EXISTS `tags_index`; |
2195 |
DROP TABLE IF EXISTS `tags_index`; |
| 2196 |
CREATE TABLE `tags_index` ( -- a weighted list of all tags and where they are used |
2196 |
CREATE TABLE `tags_index` ( -- a weighted list of all tags and where they are used |
| 2197 |
`term` varchar(255) NOT NULL, -- the tag |
2197 |
`term` varchar(191) NOT NULL, -- the tag |
| 2198 |
`biblionumber` int(11) NOT NULL, -- the bib record this tag was used on (biblio.biblionumber) |
2198 |
`biblionumber` int(11) NOT NULL, -- the bib record this tag was used on (biblio.biblionumber) |
| 2199 |
`weight` int(9) NOT NULL default '1', -- the number of times this term was used on this bib record |
2199 |
`weight` int(9) NOT NULL default '1', -- the number of times this term was used on this bib record |
| 2200 |
PRIMARY KEY (`term`,`biblionumber`), |
2200 |
PRIMARY KEY (`term`,`biblionumber`), |
|
Lines 2203-2209
CREATE TABLE `tags_index` ( -- a weighted list of all tags and where they are us
Link Here
|
| 2203 |
REFERENCES `tags_approval` (`term`) ON DELETE CASCADE ON UPDATE CASCADE, |
2203 |
REFERENCES `tags_approval` (`term`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2204 |
CONSTRAINT `tags_index_biblionumber_fk_1` FOREIGN KEY (`biblionumber`) |
2204 |
CONSTRAINT `tags_index_biblionumber_fk_1` FOREIGN KEY (`biblionumber`) |
| 2205 |
REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
2205 |
REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2206 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2206 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2207 |
|
2207 |
|
| 2208 |
-- |
2208 |
-- |
| 2209 |
-- Table structure for table `userflags` |
2209 |
-- Table structure for table `userflags` |
|
Lines 2216-2222
CREATE TABLE `userflags` (
Link Here
|
| 2216 |
`flagdesc` varchar(255) default NULL, |
2216 |
`flagdesc` varchar(255) default NULL, |
| 2217 |
`defaulton` int(11) default NULL, |
2217 |
`defaulton` int(11) default NULL, |
| 2218 |
PRIMARY KEY (`bit`) |
2218 |
PRIMARY KEY (`bit`) |
| 2219 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2219 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2220 |
|
2220 |
|
| 2221 |
-- |
2221 |
-- |
| 2222 |
-- Table structure for table `virtualshelves` |
2222 |
-- Table structure for table `virtualshelves` |
|
Lines 2235-2241
CREATE TABLE `virtualshelves` ( -- information about lists (or virtual shelves)
Link Here
|
| 2235 |
`allow_change_from_others` tinyint(1) default 0, -- can others change contents? |
2235 |
`allow_change_from_others` tinyint(1) default 0, -- can others change contents? |
| 2236 |
PRIMARY KEY (`shelfnumber`), |
2236 |
PRIMARY KEY (`shelfnumber`), |
| 2237 |
CONSTRAINT `virtualshelves_ibfk_1` FOREIGN KEY (`owner`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
2237 |
CONSTRAINT `virtualshelves_ibfk_1` FOREIGN KEY (`owner`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
| 2238 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2238 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2239 |
|
2239 |
|
| 2240 |
-- |
2240 |
-- |
| 2241 |
-- Table structure for table `virtualshelfcontents` |
2241 |
-- Table structure for table `virtualshelfcontents` |
|
Lines 2253-2259
CREATE TABLE `virtualshelfcontents` ( -- information about the titles in a list
Link Here
|
| 2253 |
CONSTRAINT `virtualshelfcontents_ibfk_1` FOREIGN KEY (`shelfnumber`) REFERENCES `virtualshelves` (`shelfnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2253 |
CONSTRAINT `virtualshelfcontents_ibfk_1` FOREIGN KEY (`shelfnumber`) REFERENCES `virtualshelves` (`shelfnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2254 |
CONSTRAINT `shelfcontents_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2254 |
CONSTRAINT `shelfcontents_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2255 |
CONSTRAINT `shelfcontents_ibfk_3` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
2255 |
CONSTRAINT `shelfcontents_ibfk_3` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
| 2256 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2256 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2257 |
|
2257 |
|
| 2258 |
-- |
2258 |
-- |
| 2259 |
-- Table structure for table `virtualshelfshares` |
2259 |
-- Table structure for table `virtualshelfshares` |
|
Lines 2268-2274
CREATE TABLE `virtualshelfshares` ( -- shared private lists
Link Here
|
| 2268 |
`sharedate` datetime, -- date of invitation or acceptance of invitation |
2268 |
`sharedate` datetime, -- date of invitation or acceptance of invitation |
| 2269 |
CONSTRAINT `virtualshelfshares_ibfk_1` FOREIGN KEY (`shelfnumber`) REFERENCES `virtualshelves` (`shelfnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2269 |
CONSTRAINT `virtualshelfshares_ibfk_1` FOREIGN KEY (`shelfnumber`) REFERENCES `virtualshelves` (`shelfnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2270 |
CONSTRAINT `virtualshelfshares_ibfk_2` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
2270 |
CONSTRAINT `virtualshelfshares_ibfk_2` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL ON UPDATE SET NULL -- no cascaded delete, please see HandleDelBorrower in Members.pm |
| 2271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2272 |
|
2272 |
|
| 2273 |
-- |
2273 |
-- |
| 2274 |
-- Table structure for table `z3950servers` |
2274 |
-- Table structure for table `z3950servers` |
|
Lines 2294-2300
CREATE TABLE `z3950servers` ( -- connection information for the Z39.50 targets u
Link Here
|
| 2294 |
`sru_fields` mediumtext default NULL, -- contains the mapping between the Z3950 search fields and the specific SRU server indexes |
2294 |
`sru_fields` mediumtext default NULL, -- contains the mapping between the Z3950 search fields and the specific SRU server indexes |
| 2295 |
`add_xslt` mediumtext default NULL, -- zero or more paths to XSLT files to be processed on the search results |
2295 |
`add_xslt` mediumtext default NULL, -- zero or more paths to XSLT files to be processed on the search results |
| 2296 |
PRIMARY KEY (`id`) |
2296 |
PRIMARY KEY (`id`) |
| 2297 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2297 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2298 |
|
2298 |
|
| 2299 |
-- |
2299 |
-- |
| 2300 |
-- Table structure for table `zebraqueue` |
2300 |
-- Table structure for table `zebraqueue` |
|
Lines 2310-2316
CREATE TABLE `zebraqueue` (
Link Here
|
| 2310 |
`time` timestamp NOT NULL default CURRENT_TIMESTAMP, |
2310 |
`time` timestamp NOT NULL default CURRENT_TIMESTAMP, |
| 2311 |
PRIMARY KEY (`id`), |
2311 |
PRIMARY KEY (`id`), |
| 2312 |
KEY `zebraqueue_lookup` (`server`, `biblio_auth_number`, `operation`, `done`) |
2312 |
KEY `zebraqueue_lookup` (`server`, `biblio_auth_number`, `operation`, `done`) |
| 2313 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2313 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2314 |
|
2314 |
|
| 2315 |
-- |
2315 |
-- |
| 2316 |
-- Table structure for table `services_throttle` |
2316 |
-- Table structure for table `services_throttle` |
|
Lines 2321-2327
CREATE TABLE `services_throttle` (
Link Here
|
| 2321 |
`service_type` varchar(10) NOT NULL default '', |
2321 |
`service_type` varchar(10) NOT NULL default '', |
| 2322 |
`service_count` varchar(45) default NULL, |
2322 |
`service_count` varchar(45) default NULL, |
| 2323 |
PRIMARY KEY (`service_type`) |
2323 |
PRIMARY KEY (`service_type`) |
| 2324 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2324 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2325 |
|
2325 |
|
| 2326 |
-- |
2326 |
-- |
| 2327 |
-- Table structure for table `language_subtag_registry` |
2327 |
-- Table structure for table `language_subtag_registry` |
|
Lines 2338-2344
CREATE TABLE language_subtag_registry (
Link Here
|
| 2338 |
id int(11) NOT NULL auto_increment, |
2338 |
id int(11) NOT NULL auto_increment, |
| 2339 |
PRIMARY KEY (`id`), |
2339 |
PRIMARY KEY (`id`), |
| 2340 |
KEY `subtag` (`subtag`) |
2340 |
KEY `subtag` (`subtag`) |
| 2341 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2341 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2342 |
|
2342 |
|
| 2343 |
-- |
2343 |
-- |
| 2344 |
-- Table structure for table `language_rfc4646_to_iso639` |
2344 |
-- Table structure for table `language_rfc4646_to_iso639` |
|
Lines 2354-2360
CREATE TABLE language_rfc4646_to_iso639 (
Link Here
|
| 2354 |
id int(11) NOT NULL auto_increment, |
2354 |
id int(11) NOT NULL auto_increment, |
| 2355 |
PRIMARY KEY (`id`), |
2355 |
PRIMARY KEY (`id`), |
| 2356 |
KEY `rfc4646_subtag` (`rfc4646_subtag`) |
2356 |
KEY `rfc4646_subtag` (`rfc4646_subtag`) |
| 2357 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2357 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2358 |
|
2358 |
|
| 2359 |
-- |
2359 |
-- |
| 2360 |
-- Table structure for table `language_descriptions` |
2360 |
-- Table structure for table `language_descriptions` |
|
Lines 2370-2376
CREATE TABLE language_descriptions (
Link Here
|
| 2370 |
PRIMARY KEY (`id`), |
2370 |
PRIMARY KEY (`id`), |
| 2371 |
KEY `lang` (`lang`), |
2371 |
KEY `lang` (`lang`), |
| 2372 |
KEY `subtag_type_lang` (`subtag`, `type`, `lang`) |
2372 |
KEY `subtag_type_lang` (`subtag`, `type`, `lang`) |
| 2373 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2373 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2374 |
|
2374 |
|
| 2375 |
-- |
2375 |
-- |
| 2376 |
-- Table structure for table `language_script_bidi` |
2376 |
-- Table structure for table `language_script_bidi` |
|
Lines 2382-2388
CREATE TABLE language_script_bidi (
Link Here
|
| 2382 |
rfc4646_subtag varchar(25), -- script subtag, Arab, Hebr, etc. |
2382 |
rfc4646_subtag varchar(25), -- script subtag, Arab, Hebr, etc. |
| 2383 |
bidi varchar(3), -- rtl ltr |
2383 |
bidi varchar(3), -- rtl ltr |
| 2384 |
KEY `rfc4646_subtag` (`rfc4646_subtag`) |
2384 |
KEY `rfc4646_subtag` (`rfc4646_subtag`) |
| 2385 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2385 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2386 |
|
2386 |
|
| 2387 |
-- |
2387 |
-- |
| 2388 |
-- Table structure for table `language_script_mapping` |
2388 |
-- Table structure for table `language_script_mapping` |
|
Lines 2395-2401
CREATE TABLE language_script_mapping (
Link Here
|
| 2395 |
language_subtag varchar(25), |
2395 |
language_subtag varchar(25), |
| 2396 |
script_subtag varchar(25), |
2396 |
script_subtag varchar(25), |
| 2397 |
KEY `language_subtag` (`language_subtag`) |
2397 |
KEY `language_subtag` (`language_subtag`) |
| 2398 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2398 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2399 |
|
2399 |
|
| 2400 |
-- |
2400 |
-- |
| 2401 |
-- Table structure for table `permissions` |
2401 |
-- Table structure for table `permissions` |
|
Lines 2409-2415
CREATE TABLE `permissions` (
Link Here
|
| 2409 |
PRIMARY KEY (`module_bit`, `code`), |
2409 |
PRIMARY KEY (`module_bit`, `code`), |
| 2410 |
CONSTRAINT `permissions_ibfk_1` FOREIGN KEY (`module_bit`) REFERENCES `userflags` (`bit`) |
2410 |
CONSTRAINT `permissions_ibfk_1` FOREIGN KEY (`module_bit`) REFERENCES `userflags` (`bit`) |
| 2411 |
ON DELETE CASCADE ON UPDATE CASCADE |
2411 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 2412 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2412 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2413 |
|
2413 |
|
| 2414 |
-- |
2414 |
-- |
| 2415 |
-- Table structure for table `serialitems` |
2415 |
-- Table structure for table `serialitems` |
|
Lines 2423-2429
CREATE TABLE `serialitems` (
Link Here
|
| 2423 |
KEY `serialitems_sfk_1` (`serialid`), |
2423 |
KEY `serialitems_sfk_1` (`serialid`), |
| 2424 |
CONSTRAINT `serialitems_sfk_1` FOREIGN KEY (`serialid`) REFERENCES `serial` (`serialid`) ON DELETE CASCADE ON UPDATE CASCADE, |
2424 |
CONSTRAINT `serialitems_sfk_1` FOREIGN KEY (`serialid`) REFERENCES `serial` (`serialid`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2425 |
CONSTRAINT `serialitems_sfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
2425 |
CONSTRAINT `serialitems_sfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2426 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2426 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2427 |
|
2427 |
|
| 2428 |
-- |
2428 |
-- |
| 2429 |
-- Table structure for table `user_permissions` |
2429 |
-- Table structure for table `user_permissions` |
|
Lines 2438-2444
CREATE TABLE `user_permissions` (
Link Here
|
| 2438 |
ON DELETE CASCADE ON UPDATE CASCADE, |
2438 |
ON DELETE CASCADE ON UPDATE CASCADE, |
| 2439 |
CONSTRAINT `user_permissions_ibfk_2` FOREIGN KEY (`module_bit`, `code`) REFERENCES `permissions` (`module_bit`, `code`) |
2439 |
CONSTRAINT `user_permissions_ibfk_2` FOREIGN KEY (`module_bit`, `code`) REFERENCES `permissions` (`module_bit`, `code`) |
| 2440 |
ON DELETE CASCADE ON UPDATE CASCADE |
2440 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 2441 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2441 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2442 |
|
2442 |
|
| 2443 |
-- |
2443 |
-- |
| 2444 |
-- Table structure for table `tmp_holdsqueue` |
2444 |
-- Table structure for table `tmp_holdsqueue` |
|
Lines 2461-2467
CREATE TABLE `tmp_holdsqueue` (
Link Here
|
| 2461 |
`pickbranch` varchar(10) default NULL, |
2461 |
`pickbranch` varchar(10) default NULL, |
| 2462 |
`notes` text, |
2462 |
`notes` text, |
| 2463 |
`item_level_request` tinyint(4) NOT NULL default 0 |
2463 |
`item_level_request` tinyint(4) NOT NULL default 0 |
| 2464 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2464 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2465 |
|
2465 |
|
| 2466 |
-- |
2466 |
-- |
| 2467 |
-- Table structure for table `message_transport_types` |
2467 |
-- Table structure for table `message_transport_types` |
|
Lines 2471-2477
DROP TABLE IF EXISTS `message_transport_types`;
Link Here
|
| 2471 |
CREATE TABLE `message_transport_types` ( |
2471 |
CREATE TABLE `message_transport_types` ( |
| 2472 |
`message_transport_type` varchar(20) NOT NULL, |
2472 |
`message_transport_type` varchar(20) NOT NULL, |
| 2473 |
PRIMARY KEY (`message_transport_type`) |
2473 |
PRIMARY KEY (`message_transport_type`) |
| 2474 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2474 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2475 |
|
2475 |
|
| 2476 |
-- |
2476 |
-- |
| 2477 |
-- Table structure for table `message_queue` |
2477 |
-- Table structure for table `message_queue` |
|
Lines 2496-2502
CREATE TABLE `message_queue` (
Link Here
|
| 2496 |
KEY `message_transport_type` (`message_transport_type`), |
2496 |
KEY `message_transport_type` (`message_transport_type`), |
| 2497 |
CONSTRAINT `messageq_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2497 |
CONSTRAINT `messageq_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2498 |
CONSTRAINT `messageq_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE RESTRICT ON UPDATE CASCADE |
2498 |
CONSTRAINT `messageq_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE RESTRICT ON UPDATE CASCADE |
| 2499 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2499 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2500 |
|
2500 |
|
| 2501 |
-- |
2501 |
-- |
| 2502 |
-- Table structure for table `letter` |
2502 |
-- Table structure for table `letter` |
|
Lines 2516-2522
CREATE TABLE `letter` ( -- table for all notice templates in Koha
Link Here
|
| 2516 |
PRIMARY KEY (`module`,`code`, `branchcode`, `message_transport_type`, `lang`), |
2516 |
PRIMARY KEY (`module`,`code`, `branchcode`, `message_transport_type`, `lang`), |
| 2517 |
CONSTRAINT `message_transport_type_fk` FOREIGN KEY (`message_transport_type`) |
2517 |
CONSTRAINT `message_transport_type_fk` FOREIGN KEY (`message_transport_type`) |
| 2518 |
REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
2518 |
REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2519 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2519 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2520 |
|
2520 |
|
| 2521 |
-- |
2521 |
-- |
| 2522 |
-- Table structure for table `overduerules_transport_types` |
2522 |
-- Table structure for table `overduerules_transport_types` |
|
Lines 2531-2537
CREATE TABLE overduerules_transport_types(
Link Here
|
| 2531 |
PRIMARY KEY (id), |
2531 |
PRIMARY KEY (id), |
| 2532 |
CONSTRAINT overduerules_fk FOREIGN KEY (overduerules_id) REFERENCES overduerules (overduerules_id) ON DELETE CASCADE ON UPDATE CASCADE, |
2532 |
CONSTRAINT overduerules_fk FOREIGN KEY (overduerules_id) REFERENCES overduerules (overduerules_id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2533 |
CONSTRAINT mtt_fk FOREIGN KEY (message_transport_type) REFERENCES message_transport_types (message_transport_type) ON DELETE CASCADE ON UPDATE CASCADE |
2533 |
CONSTRAINT mtt_fk FOREIGN KEY (message_transport_type) REFERENCES message_transport_types (message_transport_type) ON DELETE CASCADE ON UPDATE CASCADE |
| 2534 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2534 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2535 |
|
2535 |
|
| 2536 |
-- |
2536 |
-- |
| 2537 |
-- Table structure for table `message_attributes` |
2537 |
-- Table structure for table `message_attributes` |
|
Lines 2544-2550
CREATE TABLE `message_attributes` (
Link Here
|
| 2544 |
`takes_days` tinyint(1) NOT NULL default '0', |
2544 |
`takes_days` tinyint(1) NOT NULL default '0', |
| 2545 |
PRIMARY KEY (`message_attribute_id`), |
2545 |
PRIMARY KEY (`message_attribute_id`), |
| 2546 |
UNIQUE KEY `message_name` (`message_name`) |
2546 |
UNIQUE KEY `message_name` (`message_name`) |
| 2547 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2547 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2548 |
|
2548 |
|
| 2549 |
-- |
2549 |
-- |
| 2550 |
-- Table structure for table `message_transports` |
2550 |
-- Table structure for table `message_transports` |
|
Lines 2563-2569
CREATE TABLE `message_transports` (
Link Here
|
| 2563 |
KEY `letter_module` (`letter_module`,`letter_code`), |
2563 |
KEY `letter_module` (`letter_module`,`letter_code`), |
| 2564 |
CONSTRAINT `message_transports_ibfk_1` FOREIGN KEY (`message_attribute_id`) REFERENCES `message_attributes` (`message_attribute_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
2564 |
CONSTRAINT `message_transports_ibfk_1` FOREIGN KEY (`message_attribute_id`) REFERENCES `message_attributes` (`message_attribute_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2565 |
CONSTRAINT `message_transports_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
2565 |
CONSTRAINT `message_transports_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2566 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2566 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2567 |
|
2567 |
|
| 2568 |
-- |
2568 |
-- |
| 2569 |
-- Table structure for table `borrower_files` |
2569 |
-- Table structure for table `borrower_files` |
|
Lines 2581-2587
CREATE TABLE IF NOT EXISTS `borrower_files` ( -- files attached to the patron/bo
Link Here
|
| 2581 |
PRIMARY KEY (`file_id`), |
2581 |
PRIMARY KEY (`file_id`), |
| 2582 |
KEY `borrowernumber` (`borrowernumber`), |
2582 |
KEY `borrowernumber` (`borrowernumber`), |
| 2583 |
CONSTRAINT borrower_files_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
2583 |
CONSTRAINT borrower_files_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 2584 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2584 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2585 |
|
2585 |
|
| 2586 |
-- |
2586 |
-- |
| 2587 |
-- Table structure for table `borrower_message_preferences` |
2587 |
-- Table structure for table `borrower_message_preferences` |
|
Lines 2602-2608
CREATE TABLE `borrower_message_preferences` (
Link Here
|
| 2602 |
CONSTRAINT `borrower_message_preferences_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2602 |
CONSTRAINT `borrower_message_preferences_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2603 |
CONSTRAINT `borrower_message_preferences_ibfk_2` FOREIGN KEY (`message_attribute_id`) REFERENCES `message_attributes` (`message_attribute_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
2603 |
CONSTRAINT `borrower_message_preferences_ibfk_2` FOREIGN KEY (`message_attribute_id`) REFERENCES `message_attributes` (`message_attribute_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2604 |
CONSTRAINT `borrower_message_preferences_ibfk_3` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`) ON DELETE CASCADE ON UPDATE CASCADE |
2604 |
CONSTRAINT `borrower_message_preferences_ibfk_3` FOREIGN KEY (`categorycode`) REFERENCES `categories` (`categorycode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2605 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2605 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2606 |
|
2606 |
|
| 2607 |
-- |
2607 |
-- |
| 2608 |
-- Table structure for table `borrower_message_transport_preferences` |
2608 |
-- Table structure for table `borrower_message_transport_preferences` |
|
Lines 2616-2622
CREATE TABLE `borrower_message_transport_preferences` (
Link Here
|
| 2616 |
KEY `message_transport_type` (`message_transport_type`), |
2616 |
KEY `message_transport_type` (`message_transport_type`), |
| 2617 |
CONSTRAINT `borrower_message_transport_preferences_ibfk_1` FOREIGN KEY (`borrower_message_preference_id`) REFERENCES `borrower_message_preferences` (`borrower_message_preference_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
2617 |
CONSTRAINT `borrower_message_transport_preferences_ibfk_1` FOREIGN KEY (`borrower_message_preference_id`) REFERENCES `borrower_message_preferences` (`borrower_message_preference_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2618 |
CONSTRAINT `borrower_message_transport_preferences_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
2618 |
CONSTRAINT `borrower_message_transport_preferences_ibfk_2` FOREIGN KEY (`message_transport_type`) REFERENCES `message_transport_types` (`message_transport_type`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2619 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2619 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2620 |
|
2620 |
|
| 2621 |
-- |
2621 |
-- |
| 2622 |
-- Table structure for the table branch_transfer_limits |
2622 |
-- Table structure for the table branch_transfer_limits |
|
Lines 2630-2636
CREATE TABLE branch_transfer_limits (
Link Here
|
| 2630 |
itemtype varchar(10) NULL, |
2630 |
itemtype varchar(10) NULL, |
| 2631 |
ccode varchar(10) NULL, |
2631 |
ccode varchar(10) NULL, |
| 2632 |
PRIMARY KEY (limitId) |
2632 |
PRIMARY KEY (limitId) |
| 2633 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2633 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2634 |
|
2634 |
|
| 2635 |
-- |
2635 |
-- |
| 2636 |
-- Table structure for table `item_circulation_alert_preferences` |
2636 |
-- Table structure for table `item_circulation_alert_preferences` |
|
Lines 2645-2651
CREATE TABLE `item_circulation_alert_preferences` (
Link Here
|
| 2645 |
`notification` varchar(16) NOT NULL, |
2645 |
`notification` varchar(16) NOT NULL, |
| 2646 |
PRIMARY KEY (`id`), |
2646 |
PRIMARY KEY (`id`), |
| 2647 |
KEY `branchcode` (`branchcode`,`categorycode`,`item_type`, `notification`) |
2647 |
KEY `branchcode` (`branchcode`,`categorycode`,`item_type`, `notification`) |
| 2648 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2648 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2649 |
|
2649 |
|
| 2650 |
-- |
2650 |
-- |
| 2651 |
-- Table structure for table `messages` |
2651 |
-- Table structure for table `messages` |
|
Lines 2661-2667
CREATE TABLE `messages` ( -- circulation messages left via the patron's check ou
Link Here
|
| 2661 |
`manager_id` int(11) default NULL, -- creator of message |
2661 |
`manager_id` int(11) default NULL, -- creator of message |
| 2662 |
PRIMARY KEY (`message_id`), |
2662 |
PRIMARY KEY (`message_id`), |
| 2663 |
CONSTRAINT `messages_ibfk_1` FOREIGN KEY (`manager_id`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL |
2663 |
CONSTRAINT `messages_ibfk_1` FOREIGN KEY (`manager_id`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE SET NULL |
| 2664 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2664 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2665 |
|
2665 |
|
| 2666 |
-- |
2666 |
-- |
| 2667 |
-- Table structure for table `accountlines` |
2667 |
-- Table structure for table `accountlines` |
|
Lines 2690-2696
CREATE TABLE `accountlines` (
Link Here
|
| 2690 |
KEY `itemnumber` (`itemnumber`), |
2690 |
KEY `itemnumber` (`itemnumber`), |
| 2691 |
CONSTRAINT `accountlines_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
2691 |
CONSTRAINT `accountlines_ibfk_1` FOREIGN KEY (`borrowernumber`) REFERENCES `borrowers` (`borrowernumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2692 |
CONSTRAINT `accountlines_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE SET NULL ON UPDATE SET NULL |
2692 |
CONSTRAINT `accountlines_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE SET NULL ON UPDATE SET NULL |
| 2693 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2693 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2694 |
|
2694 |
|
| 2695 |
-- |
2695 |
-- |
| 2696 |
-- Table structure for table `account_offset_types` |
2696 |
-- Table structure for table `account_offset_types` |
|
Lines 2700-2706
DROP TABLE IF EXISTS `account_offset_types`;
Link Here
|
| 2700 |
CREATE TABLE `account_offset_types` ( |
2700 |
CREATE TABLE `account_offset_types` ( |
| 2701 |
`type` varchar(16) NOT NULL, -- The type of offset this is |
2701 |
`type` varchar(16) NOT NULL, -- The type of offset this is |
| 2702 |
PRIMARY KEY (`type`) |
2702 |
PRIMARY KEY (`type`) |
| 2703 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2703 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2704 |
|
2704 |
|
| 2705 |
-- |
2705 |
-- |
| 2706 |
-- Table structure for table `account_offsets` |
2706 |
-- Table structure for table `account_offsets` |
|
Lines 2718-2724
CREATE TABLE `account_offsets` (
Link Here
|
| 2718 |
CONSTRAINT `account_offsets_ibfk_p` FOREIGN KEY (`credit_id`) REFERENCES `accountlines` (`accountlines_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
2718 |
CONSTRAINT `account_offsets_ibfk_p` FOREIGN KEY (`credit_id`) REFERENCES `accountlines` (`accountlines_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2719 |
CONSTRAINT `account_offsets_ibfk_f` FOREIGN KEY (`debit_id`) REFERENCES `accountlines` (`accountlines_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
2719 |
CONSTRAINT `account_offsets_ibfk_f` FOREIGN KEY (`debit_id`) REFERENCES `accountlines` (`accountlines_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2720 |
CONSTRAINT `account_offsets_ibfk_t` FOREIGN KEY (`type`) REFERENCES `account_offset_types` (`type`) ON DELETE CASCADE ON UPDATE CASCADE |
2720 |
CONSTRAINT `account_offsets_ibfk_t` FOREIGN KEY (`type`) REFERENCES `account_offset_types` (`type`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2721 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2721 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2722 |
|
2722 |
|
| 2723 |
-- |
2723 |
-- |
| 2724 |
-- Table structure for table `action_logs` |
2724 |
-- Table structure for table `action_logs` |
|
Lines 2742-2748
CREATE TABLE `action_logs` ( -- logs of actions taken in Koha (requires that the
Link Here
|
| 2742 |
KEY `object_idx` (`object`), |
2742 |
KEY `object_idx` (`object`), |
| 2743 |
KEY `info_idx` (`info`(255)), |
2743 |
KEY `info_idx` (`info`(255)), |
| 2744 |
KEY `interface` (`interface`) |
2744 |
KEY `interface` (`interface`) |
| 2745 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2745 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2746 |
|
2746 |
|
| 2747 |
-- |
2747 |
-- |
| 2748 |
-- Table structure for table `alert` |
2748 |
-- Table structure for table `alert` |
|
Lines 2757-2763
CREATE TABLE `alert` (
Link Here
|
| 2757 |
PRIMARY KEY (`alertid`), |
2757 |
PRIMARY KEY (`alertid`), |
| 2758 |
KEY `borrowernumber` (`borrowernumber`), |
2758 |
KEY `borrowernumber` (`borrowernumber`), |
| 2759 |
KEY `type` (`type`,`externalid`) |
2759 |
KEY `type` (`type`,`externalid`) |
| 2760 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2760 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2761 |
|
2761 |
|
| 2762 |
-- |
2762 |
-- |
| 2763 |
-- Table structure for table `aqbooksellers` |
2763 |
-- Table structure for table `aqbooksellers` |
|
Lines 2797-2803
CREATE TABLE `aqbooksellers` ( -- information about the vendors listed in acquis
Link Here
|
| 2797 |
KEY `name` (`name`(255)), |
2797 |
KEY `name` (`name`(255)), |
| 2798 |
CONSTRAINT `aqbooksellers_ibfk_1` FOREIGN KEY (`listprice`) REFERENCES `currency` (`currency`) ON DELETE CASCADE ON UPDATE CASCADE, |
2798 |
CONSTRAINT `aqbooksellers_ibfk_1` FOREIGN KEY (`listprice`) REFERENCES `currency` (`currency`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 2799 |
CONSTRAINT `aqbooksellers_ibfk_2` FOREIGN KEY (`invoiceprice`) REFERENCES `currency` (`currency`) ON DELETE CASCADE ON UPDATE CASCADE |
2799 |
CONSTRAINT `aqbooksellers_ibfk_2` FOREIGN KEY (`invoiceprice`) REFERENCES `currency` (`currency`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2800 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2800 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2801 |
|
2801 |
|
| 2802 |
-- |
2802 |
-- |
| 2803 |
-- Table structure for table `aqbasketgroups` |
2803 |
-- Table structure for table `aqbasketgroups` |
|
Lines 2816-2822
CREATE TABLE `aqbasketgroups` (
Link Here
|
| 2816 |
PRIMARY KEY (`id`), |
2816 |
PRIMARY KEY (`id`), |
| 2817 |
KEY `booksellerid` (`booksellerid`), |
2817 |
KEY `booksellerid` (`booksellerid`), |
| 2818 |
CONSTRAINT `aqbasketgroups_ibfk_1` FOREIGN KEY (`booksellerid`) REFERENCES `aqbooksellers` (`id`) ON UPDATE CASCADE ON DELETE CASCADE |
2818 |
CONSTRAINT `aqbasketgroups_ibfk_1` FOREIGN KEY (`booksellerid`) REFERENCES `aqbooksellers` (`id`) ON UPDATE CASCADE ON DELETE CASCADE |
| 2819 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2819 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2820 |
|
2820 |
|
| 2821 |
-- |
2821 |
-- |
| 2822 |
-- Table structure for table `aqbudgets` |
2822 |
-- Table structure for table `aqbudgets` |
|
Lines 2845-2851
CREATE TABLE `aqbudgets` ( -- information related to Funds
Link Here
|
| 2845 |
KEY `budget_branchcode` (`budget_branchcode`), |
2845 |
KEY `budget_branchcode` (`budget_branchcode`), |
| 2846 |
KEY `budget_period_id` (`budget_period_id`), |
2846 |
KEY `budget_period_id` (`budget_period_id`), |
| 2847 |
KEY `budget_owner_id` (`budget_owner_id`) |
2847 |
KEY `budget_owner_id` (`budget_owner_id`) |
| 2848 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2848 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2849 |
|
2849 |
|
| 2850 |
-- |
2850 |
-- |
| 2851 |
-- Table structure for table aqbudgetborrowers |
2851 |
-- Table structure for table aqbudgetborrowers |
|
Lines 2862-2868
CREATE TABLE aqbudgetborrowers (
Link Here
|
| 2862 |
CONSTRAINT aqbudgetborrowers_ibfk_2 FOREIGN KEY (borrowernumber) |
2862 |
CONSTRAINT aqbudgetborrowers_ibfk_2 FOREIGN KEY (borrowernumber) |
| 2863 |
REFERENCES borrowers (borrowernumber) |
2863 |
REFERENCES borrowers (borrowernumber) |
| 2864 |
ON DELETE CASCADE ON UPDATE CASCADE |
2864 |
ON DELETE CASCADE ON UPDATE CASCADE |
| 2865 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2865 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2866 |
|
2866 |
|
| 2867 |
-- |
2867 |
-- |
| 2868 |
-- Table structure for table `aqbudgetperiods` |
2868 |
-- Table structure for table `aqbudgetperiods` |
|
Lines 2881-2887
CREATE TABLE `aqbudgetperiods` ( -- information related to Budgets
Link Here
|
| 2881 |
`sort1_authcat` varchar(10) default NULL, -- statistical category for this budget |
2881 |
`sort1_authcat` varchar(10) default NULL, -- statistical category for this budget |
| 2882 |
`sort2_authcat` varchar(10) default NULL, -- second statistical category for this budget |
2882 |
`sort2_authcat` varchar(10) default NULL, -- second statistical category for this budget |
| 2883 |
PRIMARY KEY (`budget_period_id`) |
2883 |
PRIMARY KEY (`budget_period_id`) |
| 2884 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2884 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2885 |
|
2885 |
|
| 2886 |
-- |
2886 |
-- |
| 2887 |
-- Table structure for table `aqbudgets_planning` |
2887 |
-- Table structure for table `aqbudgets_planning` |
|
Lines 2899-2905
CREATE TABLE `aqbudgets_planning` (
Link Here
|
| 2899 |
PRIMARY KEY (`plan_id`), |
2899 |
PRIMARY KEY (`plan_id`), |
| 2900 |
KEY `budget_period_id` (`budget_period_id`), |
2900 |
KEY `budget_period_id` (`budget_period_id`), |
| 2901 |
CONSTRAINT `aqbudgets_planning_ifbk_1` FOREIGN KEY (`budget_id`) REFERENCES `aqbudgets` (`budget_id`) ON DELETE CASCADE ON UPDATE CASCADE |
2901 |
CONSTRAINT `aqbudgets_planning_ifbk_1` FOREIGN KEY (`budget_id`) REFERENCES `aqbudgets` (`budget_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2902 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2902 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2903 |
|
2903 |
|
| 2904 |
-- |
2904 |
-- |
| 2905 |
-- Table structure for table 'aqcontacts' |
2905 |
-- Table structure for table 'aqcontacts' |
|
Lines 2924-2930
CREATE TABLE aqcontacts (
Link Here
|
| 2924 |
PRIMARY KEY (id), |
2924 |
PRIMARY KEY (id), |
| 2925 |
CONSTRAINT booksellerid_aqcontacts_fk FOREIGN KEY (booksellerid) |
2925 |
CONSTRAINT booksellerid_aqcontacts_fk FOREIGN KEY (booksellerid) |
| 2926 |
REFERENCES aqbooksellers (id) ON DELETE CASCADE ON UPDATE CASCADE |
2926 |
REFERENCES aqbooksellers (id) ON DELETE CASCADE ON UPDATE CASCADE |
| 2927 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1; |
2927 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci AUTO_INCREMENT=1; |
| 2928 |
|
2928 |
|
| 2929 |
-- |
2929 |
-- |
| 2930 |
-- Table structure for table 'aqcontract' |
2930 |
-- Table structure for table 'aqcontract' |
|
Lines 2941-2947
CREATE TABLE `aqcontract` (
Link Here
|
| 2941 |
PRIMARY KEY (`contractnumber`), |
2941 |
PRIMARY KEY (`contractnumber`), |
| 2942 |
CONSTRAINT `booksellerid_fk1` FOREIGN KEY (`booksellerid`) |
2942 |
CONSTRAINT `booksellerid_fk1` FOREIGN KEY (`booksellerid`) |
| 2943 |
REFERENCES `aqbooksellers` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
2943 |
REFERENCES `aqbooksellers` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 2944 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; |
2944 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci AUTO_INCREMENT=1 ; |
| 2945 |
|
2945 |
|
| 2946 |
-- |
2946 |
-- |
| 2947 |
-- Table structure for table `aqbasket` |
2947 |
-- Table structure for table `aqbasket` |
|
Lines 2974-2980
CREATE TABLE `aqbasket` ( -- stores data about baskets in acquisitions
Link Here
|
| 2974 |
CONSTRAINT `aqbasket_ibfk_2` FOREIGN KEY (`contractnumber`) REFERENCES `aqcontract` (`contractnumber`), |
2974 |
CONSTRAINT `aqbasket_ibfk_2` FOREIGN KEY (`contractnumber`) REFERENCES `aqcontract` (`contractnumber`), |
| 2975 |
CONSTRAINT `aqbasket_ibfk_3` FOREIGN KEY (`basketgroupid`) REFERENCES `aqbasketgroups` (`id`) ON UPDATE CASCADE, |
2975 |
CONSTRAINT `aqbasket_ibfk_3` FOREIGN KEY (`basketgroupid`) REFERENCES `aqbasketgroups` (`id`) ON UPDATE CASCADE, |
| 2976 |
CONSTRAINT aqbasket_ibfk_4 FOREIGN KEY (branch) REFERENCES branches (branchcode) ON UPDATE CASCADE ON DELETE SET NULL |
2976 |
CONSTRAINT aqbasket_ibfk_4 FOREIGN KEY (branch) REFERENCES branches (branchcode) ON UPDATE CASCADE ON DELETE SET NULL |
| 2977 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2977 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2978 |
|
2978 |
|
| 2979 |
-- |
2979 |
-- |
| 2980 |
-- Table structure for table aqbasketusers |
2980 |
-- Table structure for table aqbasketusers |
|
Lines 2987-2993
CREATE TABLE aqbasketusers (
Link Here
|
| 2987 |
PRIMARY KEY (basketno,borrowernumber), |
2987 |
PRIMARY KEY (basketno,borrowernumber), |
| 2988 |
CONSTRAINT aqbasketusers_ibfk_1 FOREIGN KEY (basketno) REFERENCES aqbasket (basketno) ON UPDATE CASCADE ON DELETE CASCADE, |
2988 |
CONSTRAINT aqbasketusers_ibfk_1 FOREIGN KEY (basketno) REFERENCES aqbasket (basketno) ON UPDATE CASCADE ON DELETE CASCADE, |
| 2989 |
CONSTRAINT aqbasketusers_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON UPDATE CASCADE ON DELETE CASCADE |
2989 |
CONSTRAINT aqbasketusers_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON UPDATE CASCADE ON DELETE CASCADE |
| 2990 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
2990 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 2991 |
|
2991 |
|
| 2992 |
-- |
2992 |
-- |
| 2993 |
-- Table structure for table `suggestions` |
2993 |
-- Table structure for table `suggestions` |
|
Lines 3033-3039
CREATE TABLE `suggestions` ( -- purchase suggestions
Link Here
|
| 3033 |
KEY `biblionumber` (`biblionumber`), |
3033 |
KEY `biblionumber` (`biblionumber`), |
| 3034 |
KEY `branchcode` (`branchcode`), |
3034 |
KEY `branchcode` (`branchcode`), |
| 3035 |
CONSTRAINT `suggestions_budget_id_fk` FOREIGN KEY (`budgetid`) REFERENCES `aqbudgets` (`budget_id`) ON DELETE SET NULL ON UPDATE CASCADE |
3035 |
CONSTRAINT `suggestions_budget_id_fk` FOREIGN KEY (`budgetid`) REFERENCES `aqbudgets` (`budget_id`) ON DELETE SET NULL ON UPDATE CASCADE |
| 3036 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3036 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3037 |
|
3037 |
|
| 3038 |
-- |
3038 |
-- |
| 3039 |
-- Table structure for table vendor_edi_accounts |
3039 |
-- Table structure for table vendor_edi_accounts |
|
Lines 3065-3071
CREATE TABLE IF NOT EXISTS vendor_edi_accounts (
Link Here
|
| 3065 |
KEY shipmentbudget (shipment_budget), |
3065 |
KEY shipmentbudget (shipment_budget), |
| 3066 |
CONSTRAINT vfk_vendor_id FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ), |
3066 |
CONSTRAINT vfk_vendor_id FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ), |
| 3067 |
CONSTRAINT vfk_shipment_budget FOREIGN KEY ( shipment_budget ) REFERENCES aqbudgets ( budget_id ) |
3067 |
CONSTRAINT vfk_shipment_budget FOREIGN KEY ( shipment_budget ) REFERENCES aqbudgets ( budget_id ) |
| 3068 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3068 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3069 |
|
3069 |
|
| 3070 |
-- |
3070 |
-- |
| 3071 |
-- Table structure for table edifact_messages |
3071 |
-- Table structure for table edifact_messages |
|
Lines 3090-3096
CREATE TABLE IF NOT EXISTS edifact_messages (
Link Here
|
| 3090 |
CONSTRAINT emfk_vendor FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ) ON DELETE CASCADE ON UPDATE CASCADE, |
3090 |
CONSTRAINT emfk_vendor FOREIGN KEY ( vendor_id ) REFERENCES aqbooksellers ( id ) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3091 |
CONSTRAINT emfk_edi_acct FOREIGN KEY ( edi_acct ) REFERENCES vendor_edi_accounts ( id ) ON DELETE CASCADE ON UPDATE CASCADE, |
3091 |
CONSTRAINT emfk_edi_acct FOREIGN KEY ( edi_acct ) REFERENCES vendor_edi_accounts ( id ) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3092 |
CONSTRAINT emfk_basketno FOREIGN KEY ( basketno ) REFERENCES aqbasket ( basketno ) ON DELETE CASCADE ON UPDATE CASCADE |
3092 |
CONSTRAINT emfk_basketno FOREIGN KEY ( basketno ) REFERENCES aqbasket ( basketno ) ON DELETE CASCADE ON UPDATE CASCADE |
| 3093 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3093 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3094 |
|
3094 |
|
| 3095 |
-- |
3095 |
-- |
| 3096 |
-- Table structure for table aqinvoices |
3096 |
-- Table structure for table aqinvoices |
|
Lines 3111-3117
CREATE TABLE aqinvoices (
Link Here
|
| 3111 |
CONSTRAINT aqinvoices_fk_aqbooksellerid FOREIGN KEY (booksellerid) REFERENCES aqbooksellers (id) ON DELETE CASCADE ON UPDATE CASCADE, |
3111 |
CONSTRAINT aqinvoices_fk_aqbooksellerid FOREIGN KEY (booksellerid) REFERENCES aqbooksellers (id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3112 |
CONSTRAINT edifact_msg_fk FOREIGN KEY ( message_id ) REFERENCES edifact_messages ( id ) ON DELETE SET NULL, |
3112 |
CONSTRAINT edifact_msg_fk FOREIGN KEY ( message_id ) REFERENCES edifact_messages ( id ) ON DELETE SET NULL, |
| 3113 |
CONSTRAINT aqinvoices_fk_shipmentcost_budgetid FOREIGN KEY (shipmentcost_budgetid) REFERENCES aqbudgets (budget_id) ON DELETE SET NULL ON UPDATE CASCADE |
3113 |
CONSTRAINT aqinvoices_fk_shipmentcost_budgetid FOREIGN KEY (shipmentcost_budgetid) REFERENCES aqbudgets (budget_id) ON DELETE SET NULL ON UPDATE CASCADE |
| 3114 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3114 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3115 |
|
3115 |
|
| 3116 |
-- |
3116 |
-- |
| 3117 |
-- Table structure for table `aqorders` |
3117 |
-- Table structure for table `aqorders` |
|
Lines 3167-3173
CREATE TABLE `aqorders` ( -- information related to the basket line items
Link Here
|
| 3167 |
line_item_id varchar(35) default NULL, -- Supplier's article id for Edifact orderline |
3167 |
line_item_id varchar(35) default NULL, -- Supplier's article id for Edifact orderline |
| 3168 |
suppliers_reference_number varchar(35) default NULL, -- Suppliers unique edifact quote ref |
3168 |
suppliers_reference_number varchar(35) default NULL, -- Suppliers unique edifact quote ref |
| 3169 |
suppliers_reference_qualifier varchar(3) default NULL, -- Type of number above usually 'QLI' |
3169 |
suppliers_reference_qualifier varchar(3) default NULL, -- Type of number above usually 'QLI' |
| 3170 |
`suppliers_report` text COLLATE utf8_unicode_ci, -- reports received from suppliers |
3170 |
`suppliers_report` text COLLATE utf8mb4_unicode_ci, -- reports received from suppliers |
| 3171 |
PRIMARY KEY (`ordernumber`), |
3171 |
PRIMARY KEY (`ordernumber`), |
| 3172 |
KEY `basketno` (`basketno`), |
3172 |
KEY `basketno` (`basketno`), |
| 3173 |
KEY `biblionumber` (`biblionumber`), |
3173 |
KEY `biblionumber` (`biblionumber`), |
|
Lines 3180-3186
CREATE TABLE `aqorders` ( -- information related to the basket line items
Link Here
|
| 3180 |
CONSTRAINT aqorders_ibfk_3 FOREIGN KEY (invoiceid) REFERENCES aqinvoices (invoiceid) ON DELETE SET NULL ON UPDATE CASCADE, |
3180 |
CONSTRAINT aqorders_ibfk_3 FOREIGN KEY (invoiceid) REFERENCES aqinvoices (invoiceid) ON DELETE SET NULL ON UPDATE CASCADE, |
| 3181 |
CONSTRAINT `aqorders_subscriptionid` FOREIGN KEY (`subscriptionid`) REFERENCES `subscription` (`subscriptionid`) ON DELETE CASCADE ON UPDATE CASCADE, |
3181 |
CONSTRAINT `aqorders_subscriptionid` FOREIGN KEY (`subscriptionid`) REFERENCES `subscription` (`subscriptionid`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3182 |
CONSTRAINT `aqorders_currency` FOREIGN KEY (`currency`) REFERENCES `currency` (`currency`) ON DELETE SET NULL ON UPDATE SET NULL |
3182 |
CONSTRAINT `aqorders_currency` FOREIGN KEY (`currency`) REFERENCES `currency` (`currency`) ON DELETE SET NULL ON UPDATE SET NULL |
| 3183 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3183 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3184 |
|
3184 |
|
| 3185 |
-- |
3185 |
-- |
| 3186 |
-- Table structure for table `aqorder_users` |
3186 |
-- Table structure for table `aqorder_users` |
|
Lines 3193-3199
CREATE TABLE aqorder_users ( -- Mapping orders to patrons for notification sendi
Link Here
|
| 3193 |
PRIMARY KEY (ordernumber, borrowernumber), |
3193 |
PRIMARY KEY (ordernumber, borrowernumber), |
| 3194 |
CONSTRAINT aqorder_users_ibfk_1 FOREIGN KEY (ordernumber) REFERENCES aqorders (ordernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
3194 |
CONSTRAINT aqorder_users_ibfk_1 FOREIGN KEY (ordernumber) REFERENCES aqorders (ordernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3195 |
CONSTRAINT aqorder_users_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
3195 |
CONSTRAINT aqorder_users_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 3196 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3196 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3197 |
|
3197 |
|
| 3198 |
-- |
3198 |
-- |
| 3199 |
-- Table structure for table `aqorders_items` |
3199 |
-- Table structure for table `aqorders_items` |
|
Lines 3207-3213
CREATE TABLE `aqorders_items` ( -- information on items entered in the acquisiti
Link Here
|
| 3207 |
PRIMARY KEY (`itemnumber`), |
3207 |
PRIMARY KEY (`itemnumber`), |
| 3208 |
KEY `ordernumber` (`ordernumber`), |
3208 |
KEY `ordernumber` (`ordernumber`), |
| 3209 |
CONSTRAINT aqorders_items_ibfk_1 FOREIGN KEY (ordernumber) REFERENCES aqorders (ordernumber) ON DELETE CASCADE ON UPDATE CASCADE |
3209 |
CONSTRAINT aqorders_items_ibfk_1 FOREIGN KEY (ordernumber) REFERENCES aqorders (ordernumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 3210 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3210 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3211 |
|
3211 |
|
| 3212 |
-- |
3212 |
-- |
| 3213 |
-- Table structure for table aqorders_transfers |
3213 |
-- Table structure for table aqorders_transfers |
|
Lines 3222-3228
CREATE TABLE aqorders_transfers (
Link Here
|
| 3222 |
UNIQUE KEY ordernumber_to (ordernumber_to), |
3222 |
UNIQUE KEY ordernumber_to (ordernumber_to), |
| 3223 |
CONSTRAINT aqorders_transfers_ordernumber_from FOREIGN KEY (ordernumber_from) REFERENCES aqorders (ordernumber) ON DELETE SET NULL ON UPDATE CASCADE, |
3223 |
CONSTRAINT aqorders_transfers_ordernumber_from FOREIGN KEY (ordernumber_from) REFERENCES aqorders (ordernumber) ON DELETE SET NULL ON UPDATE CASCADE, |
| 3224 |
CONSTRAINT aqorders_transfers_ordernumber_to FOREIGN KEY (ordernumber_to) REFERENCES aqorders (ordernumber) ON DELETE SET NULL ON UPDATE CASCADE |
3224 |
CONSTRAINT aqorders_transfers_ordernumber_to FOREIGN KEY (ordernumber_to) REFERENCES aqorders (ordernumber) ON DELETE SET NULL ON UPDATE CASCADE |
| 3225 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3225 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3226 |
|
3226 |
|
| 3227 |
-- |
3227 |
-- |
| 3228 |
-- Table structure for table `fieldmapping` |
3228 |
-- Table structure for table `fieldmapping` |
|
Lines 3236-3242
CREATE TABLE `fieldmapping` ( -- koha to keyword mapping
Link Here
|
| 3236 |
`fieldcode` char(3) NOT NULL, -- marc field number to map to this keyword |
3236 |
`fieldcode` char(3) NOT NULL, -- marc field number to map to this keyword |
| 3237 |
`subfieldcode` char(1) NOT NULL, -- marc subfield associated with the fieldcode to map to this keyword |
3237 |
`subfieldcode` char(1) NOT NULL, -- marc subfield associated with the fieldcode to map to this keyword |
| 3238 |
PRIMARY KEY (`id`) |
3238 |
PRIMARY KEY (`id`) |
| 3239 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3239 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3240 |
|
3240 |
|
| 3241 |
-- |
3241 |
-- |
| 3242 |
-- Table structure for table `transport_cost` |
3242 |
-- Table structure for table `transport_cost` |
|
Lines 3252-3258
CREATE TABLE transport_cost (
Link Here
|
| 3252 |
PRIMARY KEY (frombranch, tobranch), |
3252 |
PRIMARY KEY (frombranch, tobranch), |
| 3253 |
CONSTRAINT transport_cost_ibfk_1 FOREIGN KEY (frombranch) REFERENCES branches (branchcode) ON DELETE CASCADE ON UPDATE CASCADE, |
3253 |
CONSTRAINT transport_cost_ibfk_1 FOREIGN KEY (frombranch) REFERENCES branches (branchcode) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3254 |
CONSTRAINT transport_cost_ibfk_2 FOREIGN KEY (tobranch) REFERENCES branches (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
3254 |
CONSTRAINT transport_cost_ibfk_2 FOREIGN KEY (tobranch) REFERENCES branches (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3255 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3255 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3256 |
|
3256 |
|
| 3257 |
-- |
3257 |
-- |
| 3258 |
-- Table structure for table `biblioimages` |
3258 |
-- Table structure for table `biblioimages` |
|
Lines 3268-3274
CREATE TABLE `biblioimages` ( -- local cover images
Link Here
|
| 3268 |
`thumbnail` mediumblob NOT NULL, -- thumbnail file contents |
3268 |
`thumbnail` mediumblob NOT NULL, -- thumbnail file contents |
| 3269 |
PRIMARY KEY (`imagenumber`), |
3269 |
PRIMARY KEY (`imagenumber`), |
| 3270 |
CONSTRAINT `bibliocoverimage_fk1` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
3270 |
CONSTRAINT `bibliocoverimage_fk1` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3271 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3272 |
|
3272 |
|
| 3273 |
-- |
3273 |
-- |
| 3274 |
-- Table structure for table `social_data` |
3274 |
-- Table structure for table `social_data` |
|
Lines 3284-3290
CREATE TABLE IF NOT EXISTS `social_data` (
Link Here
|
| 3284 |
`score_avg` DECIMAL(5,2), |
3284 |
`score_avg` DECIMAL(5,2), |
| 3285 |
`num_scores` INT, |
3285 |
`num_scores` INT, |
| 3286 |
PRIMARY KEY (`isbn`) |
3286 |
PRIMARY KEY (`isbn`) |
| 3287 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3287 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3288 |
|
3288 |
|
| 3289 |
-- |
3289 |
-- |
| 3290 |
-- 'Ratings' table. This tracks the star ratings set by borrowers. |
3290 |
-- 'Ratings' table. This tracks the star ratings set by borrowers. |
|
Lines 3299-3305
CREATE TABLE ratings ( -- information related to the star ratings in the OPAC
Link Here
|
| 3299 |
PRIMARY KEY (borrowernumber,biblionumber), |
3299 |
PRIMARY KEY (borrowernumber,biblionumber), |
| 3300 |
CONSTRAINT ratings_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
3300 |
CONSTRAINT ratings_ibfk_1 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3301 |
CONSTRAINT ratings_ibfk_2 FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE |
3301 |
CONSTRAINT ratings_ibfk_2 FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 3302 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3302 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3303 |
|
3303 |
|
| 3304 |
-- |
3304 |
-- |
| 3305 |
-- Table structure for table `quotes` |
3305 |
-- Table structure for table `quotes` |
|
Lines 3312-3318
CREATE TABLE `quotes` ( -- data for the quote of the day feature
Link Here
|
| 3312 |
`text` mediumtext NOT NULL, -- text of the quote |
3312 |
`text` mediumtext NOT NULL, -- text of the quote |
| 3313 |
`timestamp` datetime NOT NULL, -- date and time that the quote last appeared in the opac |
3313 |
`timestamp` datetime NOT NULL, -- date and time that the quote last appeared in the opac |
| 3314 |
PRIMARY KEY (`id`) |
3314 |
PRIMARY KEY (`id`) |
| 3315 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3315 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3316 |
|
3316 |
|
| 3317 |
-- |
3317 |
-- |
| 3318 |
-- Table structure for table categories_branches |
3318 |
-- Table structure for table categories_branches |
|
Lines 3324-3330
CREATE TABLE categories_branches( -- association table between categories and br
Link Here
|
| 3324 |
branchcode VARCHAR(10), |
3324 |
branchcode VARCHAR(10), |
| 3325 |
FOREIGN KEY (categorycode) REFERENCES categories(categorycode) ON DELETE CASCADE, |
3325 |
FOREIGN KEY (categorycode) REFERENCES categories(categorycode) ON DELETE CASCADE, |
| 3326 |
FOREIGN KEY (branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
3326 |
FOREIGN KEY (branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
| 3327 |
) ENGINE=INNODB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3327 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3328 |
|
3328 |
|
| 3329 |
-- |
3329 |
-- |
| 3330 |
-- Table structure for table authorised_values_branches |
3330 |
-- Table structure for table authorised_values_branches |
|
Lines 3336-3342
CREATE TABLE authorised_values_branches( -- association table between authorised
Link Here
|
| 3336 |
branchcode VARCHAR(10) NOT NULL, |
3336 |
branchcode VARCHAR(10) NOT NULL, |
| 3337 |
FOREIGN KEY (av_id) REFERENCES authorised_values(id) ON DELETE CASCADE, |
3337 |
FOREIGN KEY (av_id) REFERENCES authorised_values(id) ON DELETE CASCADE, |
| 3338 |
FOREIGN KEY (branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
3338 |
FOREIGN KEY (branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
| 3339 |
) ENGINE=INNODB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3339 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3340 |
|
3340 |
|
| 3341 |
|
3341 |
|
| 3342 |
-- |
3342 |
-- |
|
Lines 3349-3355
CREATE TABLE borrower_attribute_types_branches( -- association table between bor
Link Here
|
| 3349 |
b_branchcode VARCHAR(10), |
3349 |
b_branchcode VARCHAR(10), |
| 3350 |
FOREIGN KEY (bat_code) REFERENCES borrower_attribute_types(code) ON DELETE CASCADE, |
3350 |
FOREIGN KEY (bat_code) REFERENCES borrower_attribute_types(code) ON DELETE CASCADE, |
| 3351 |
FOREIGN KEY (b_branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
3351 |
FOREIGN KEY (b_branchcode) REFERENCES branches(branchcode) ON DELETE CASCADE |
| 3352 |
) ENGINE=INNODB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3352 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3353 |
|
3353 |
|
| 3354 |
-- |
3354 |
-- |
| 3355 |
-- Table structure for table `borrower_modifications` |
3355 |
-- Table structure for table `borrower_modifications` |
|
Lines 3425-3434
CREATE TABLE IF NOT EXISTS `borrower_modifications` (
Link Here
|
| 3425 |
`smsalertnumber` varchar(50) DEFAULT NULL, |
3425 |
`smsalertnumber` varchar(50) DEFAULT NULL, |
| 3426 |
`privacy` int(11) DEFAULT NULL, |
3426 |
`privacy` int(11) DEFAULT NULL, |
| 3427 |
`extended_attributes` text DEFAULT NULL, |
3427 |
`extended_attributes` text DEFAULT NULL, |
| 3428 |
PRIMARY KEY (`verification_token`,`borrowernumber`), |
3428 |
PRIMARY KEY (`verification_token` (191),`borrowernumber`), |
| 3429 |
KEY `verification_token` (`verification_token`), |
3429 |
KEY `verification_token` (`verification_token` (191)), |
| 3430 |
KEY `borrowernumber` (`borrowernumber`) |
3430 |
KEY `borrowernumber` (`borrowernumber`) |
| 3431 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3431 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3432 |
|
3432 |
|
| 3433 |
-- |
3433 |
-- |
| 3434 |
-- Table structure for table uploaded_files |
3434 |
-- Table structure for table uploaded_files |
|
Lines 3447-3453
CREATE TABLE uploaded_files (
Link Here
|
| 3447 |
public tinyint, |
3447 |
public tinyint, |
| 3448 |
permanent tinyint, |
3448 |
permanent tinyint, |
| 3449 |
PRIMARY KEY (id) |
3449 |
PRIMARY KEY (id) |
| 3450 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3450 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3451 |
|
3451 |
|
| 3452 |
-- |
3452 |
-- |
| 3453 |
-- Table structure for table linktracker |
3453 |
-- Table structure for table linktracker |
|
Lines 3467-3473
CREATE TABLE linktracker (
Link Here
|
| 3467 |
KEY itemidx (itemnumber), |
3467 |
KEY itemidx (itemnumber), |
| 3468 |
KEY borridx (borrowernumber), |
3468 |
KEY borridx (borrowernumber), |
| 3469 |
KEY dateidx (timeclicked) |
3469 |
KEY dateidx (timeclicked) |
| 3470 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3470 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3471 |
|
3471 |
|
| 3472 |
-- |
3472 |
-- |
| 3473 |
-- Table structure for table 'plugin_data' |
3473 |
-- Table structure for table 'plugin_data' |
|
Lines 3477-3484
CREATE TABLE IF NOT EXISTS plugin_data (
Link Here
|
| 3477 |
plugin_class varchar(255) NOT NULL, |
3477 |
plugin_class varchar(255) NOT NULL, |
| 3478 |
plugin_key varchar(255) NOT NULL, |
3478 |
plugin_key varchar(255) NOT NULL, |
| 3479 |
plugin_value text, |
3479 |
plugin_value text, |
| 3480 |
PRIMARY KEY (plugin_class,plugin_key) |
3480 |
PRIMARY KEY ( `plugin_class` (191), `plugin_key` (191) ) |
| 3481 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3481 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3482 |
|
3482 |
|
| 3483 |
-- |
3483 |
-- |
| 3484 |
-- Table structure for table `patron_lists` |
3484 |
-- Table structure for table `patron_lists` |
|
Lines 3487-3497
CREATE TABLE IF NOT EXISTS plugin_data (
Link Here
|
| 3487 |
DROP TABLE IF EXISTS patron_lists; |
3487 |
DROP TABLE IF EXISTS patron_lists; |
| 3488 |
CREATE TABLE patron_lists ( |
3488 |
CREATE TABLE patron_lists ( |
| 3489 |
patron_list_id int(11) NOT NULL AUTO_INCREMENT, -- unique identifier |
3489 |
patron_list_id int(11) NOT NULL AUTO_INCREMENT, -- unique identifier |
| 3490 |
name varchar(255) CHARACTER SET utf8 NOT NULL, -- the list's name |
3490 |
name varchar(255) CHARACTER SET utf8mb4 NOT NULL, -- the list's name |
| 3491 |
owner int(11) NOT NULL, -- borrowernumber of the list creator |
3491 |
owner int(11) NOT NULL, -- borrowernumber of the list creator |
| 3492 |
PRIMARY KEY (patron_list_id), |
3492 |
PRIMARY KEY (patron_list_id), |
| 3493 |
KEY owner (owner) |
3493 |
KEY owner (owner) |
| 3494 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3494 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3495 |
|
3495 |
|
| 3496 |
-- |
3496 |
-- |
| 3497 |
-- Constraints for table `patron_lists` |
3497 |
-- Constraints for table `patron_lists` |
|
Lines 3511-3517
CREATE TABLE patron_list_patrons (
Link Here
|
| 3511 |
PRIMARY KEY (patron_list_patron_id), |
3511 |
PRIMARY KEY (patron_list_patron_id), |
| 3512 |
KEY patron_list_id (patron_list_id), |
3512 |
KEY patron_list_id (patron_list_id), |
| 3513 |
KEY borrowernumber (borrowernumber) |
3513 |
KEY borrowernumber (borrowernumber) |
| 3514 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3514 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3515 |
|
3515 |
|
| 3516 |
-- |
3516 |
-- |
| 3517 |
-- Constraints for table `patron_list_patrons` |
3517 |
-- Constraints for table `patron_list_patrons` |
|
Lines 3528-3534
CREATE TABLE IF NOT EXISTS marc_modification_templates (
Link Here
|
| 3528 |
template_id int(11) NOT NULL AUTO_INCREMENT, |
3528 |
template_id int(11) NOT NULL AUTO_INCREMENT, |
| 3529 |
name text NOT NULL, |
3529 |
name text NOT NULL, |
| 3530 |
PRIMARY KEY (template_id) |
3530 |
PRIMARY KEY (template_id) |
| 3531 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3531 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3532 |
|
3532 |
|
| 3533 |
-- |
3533 |
-- |
| 3534 |
-- Table structure for table 'marc_modification_template_actions' |
3534 |
-- Table structure for table 'marc_modification_template_actions' |
|
Lines 3557-3563
CREATE TABLE IF NOT EXISTS marc_modification_template_actions (
Link Here
|
| 3557 |
description text, |
3557 |
description text, |
| 3558 |
PRIMARY KEY (mmta_id), |
3558 |
PRIMARY KEY (mmta_id), |
| 3559 |
CONSTRAINT `mmta_ibfk_1` FOREIGN KEY (`template_id`) REFERENCES `marc_modification_templates` (`template_id`) ON DELETE CASCADE ON UPDATE CASCADE |
3559 |
CONSTRAINT `mmta_ibfk_1` FOREIGN KEY (`template_id`) REFERENCES `marc_modification_templates` (`template_id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3560 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3560 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3561 |
|
3561 |
|
| 3562 |
-- |
3562 |
-- |
| 3563 |
-- Table structure for table `misc_files` |
3563 |
-- Table structure for table `misc_files` |
|
Lines 3575-3581
CREATE TABLE IF NOT EXISTS `misc_files` ( -- miscellaneous files attached to rec
Link Here
|
| 3575 |
PRIMARY KEY (`file_id`), |
3575 |
PRIMARY KEY (`file_id`), |
| 3576 |
KEY `table_tag` (`table_tag`), |
3576 |
KEY `table_tag` (`table_tag`), |
| 3577 |
KEY `record_id` (`record_id`) |
3577 |
KEY `record_id` (`record_id`) |
| 3578 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3578 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3579 |
|
3579 |
|
| 3580 |
-- |
3580 |
-- |
| 3581 |
-- Table structure for table `columns_settings` |
3581 |
-- Table structure for table `columns_settings` |
|
Lines 3588-3595
CREATE TABLE IF NOT EXISTS columns_settings (
Link Here
|
| 3588 |
columnname varchar(255) NOT NULL, |
3588 |
columnname varchar(255) NOT NULL, |
| 3589 |
cannot_be_toggled int(1) NOT NULL DEFAULT 0, |
3589 |
cannot_be_toggled int(1) NOT NULL DEFAULT 0, |
| 3590 |
is_hidden int(1) NOT NULL DEFAULT 0, |
3590 |
is_hidden int(1) NOT NULL DEFAULT 0, |
| 3591 |
PRIMARY KEY(module, page, tablename, columnname) |
3591 |
PRIMARY KEY(module (191), page (191), tablename (191), columnname (191)) |
| 3592 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3592 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3593 |
|
3593 |
|
| 3594 |
-- |
3594 |
-- |
| 3595 |
-- Table structure for table 'items_search_fields' |
3595 |
-- Table structure for table 'items_search_fields' |
|
Lines 3602-3612
CREATE TABLE items_search_fields (
Link Here
|
| 3602 |
tagfield CHAR(3) NOT NULL, |
3602 |
tagfield CHAR(3) NOT NULL, |
| 3603 |
tagsubfield CHAR(1) NULL DEFAULT NULL, |
3603 |
tagsubfield CHAR(1) NULL DEFAULT NULL, |
| 3604 |
authorised_values_category VARCHAR(32) NULL DEFAULT NULL, |
3604 |
authorised_values_category VARCHAR(32) NULL DEFAULT NULL, |
| 3605 |
PRIMARY KEY(name), |
3605 |
PRIMARY KEY(name (191)), |
| 3606 |
CONSTRAINT items_search_fields_authorised_values_category |
3606 |
CONSTRAINT items_search_fields_authorised_values_category |
| 3607 |
FOREIGN KEY (authorised_values_category) REFERENCES authorised_value_categories (category_name) |
3607 |
FOREIGN KEY (authorised_values_category) REFERENCES authorised_value_categories (category_name) |
| 3608 |
ON DELETE SET NULL ON UPDATE CASCADE |
3608 |
ON DELETE SET NULL ON UPDATE CASCADE |
| 3609 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3609 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3610 |
|
3610 |
|
| 3611 |
-- |
3611 |
-- |
| 3612 |
-- Table structure for table 'discharges' |
3612 |
-- Table structure for table 'discharges' |
|
Lines 3621-3627
CREATE TABLE discharges (
Link Here
|
| 3621 |
PRIMARY KEY (discharge_id), |
3621 |
PRIMARY KEY (discharge_id), |
| 3622 |
KEY borrower_discharges_ibfk1 (borrower), |
3622 |
KEY borrower_discharges_ibfk1 (borrower), |
| 3623 |
CONSTRAINT borrower_discharges_ibfk1 FOREIGN KEY (borrower) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
3623 |
CONSTRAINT borrower_discharges_ibfk1 FOREIGN KEY (borrower) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE |
| 3624 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3624 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3625 |
|
3625 |
|
| 3626 |
-- |
3626 |
-- |
| 3627 |
-- Table structure for table additional_fields |
3627 |
-- Table structure for table additional_fields |
|
Lines 3637-3644
CREATE TABLE `additional_fields` (
Link Here
|
| 3637 |
`marcfield` varchar(16) NOT NULL DEFAULT '', -- contains the marc field to copied into the record |
3637 |
`marcfield` varchar(16) NOT NULL DEFAULT '', -- contains the marc field to copied into the record |
| 3638 |
`searchable` tinyint(1) NOT NULL DEFAULT '0', -- is the field searchable? |
3638 |
`searchable` tinyint(1) NOT NULL DEFAULT '0', -- is the field searchable? |
| 3639 |
PRIMARY KEY (`id`), |
3639 |
PRIMARY KEY (`id`), |
| 3640 |
UNIQUE KEY `fields_uniq` (`tablename`,`name`) |
3640 |
UNIQUE KEY `fields_uniq` (`tablename` (191),`name` (191)) |
| 3641 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3641 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3642 |
|
3642 |
|
| 3643 |
-- |
3643 |
-- |
| 3644 |
-- Table structure for table additional_field_values |
3644 |
-- Table structure for table additional_field_values |
|
Lines 3654-3660
CREATE TABLE `additional_field_values` (
Link Here
|
| 3654 |
PRIMARY KEY (`id`), |
3654 |
PRIMARY KEY (`id`), |
| 3655 |
UNIQUE KEY `field_record` (`field_id`,`record_id`), |
3655 |
UNIQUE KEY `field_record` (`field_id`,`record_id`), |
| 3656 |
CONSTRAINT `afv_fk` FOREIGN KEY (`field_id`) REFERENCES `additional_fields` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
3656 |
CONSTRAINT `afv_fk` FOREIGN KEY (`field_id`) REFERENCES `additional_fields` (`id`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3657 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3657 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3658 |
|
3658 |
|
| 3659 |
-- |
3659 |
-- |
| 3660 |
-- Table structure for table 'localization' |
3660 |
-- Table structure for table 'localization' |
|
Lines 3663-3675
CREATE TABLE `additional_field_values` (
Link Here
|
| 3663 |
DROP TABLE IF EXISTS localization; |
3663 |
DROP TABLE IF EXISTS localization; |
| 3664 |
CREATE TABLE `localization` ( |
3664 |
CREATE TABLE `localization` ( |
| 3665 |
localization_id int(11) NOT NULL AUTO_INCREMENT, |
3665 |
localization_id int(11) NOT NULL AUTO_INCREMENT, |
| 3666 |
entity varchar(16) COLLATE utf8_unicode_ci NOT NULL, |
3666 |
entity varchar(16) COLLATE utf8mb4_unicode_ci NOT NULL, |
| 3667 |
code varchar(64) COLLATE utf8_unicode_ci NOT NULL, |
3667 |
code varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL, |
| 3668 |
lang varchar(25) COLLATE utf8_unicode_ci NOT NULL, -- could be a foreign key |
3668 |
lang varchar(25) COLLATE utf8mb4_unicode_ci NOT NULL, -- could be a foreign key |
| 3669 |
translation text COLLATE utf8_unicode_ci, |
3669 |
translation text COLLATE utf8mb4_unicode_ci, |
| 3670 |
PRIMARY KEY (localization_id), |
3670 |
PRIMARY KEY (localization_id), |
| 3671 |
UNIQUE KEY `entity_code_lang` (`entity`,`code`,`lang`) |
3671 |
UNIQUE KEY `entity_code_lang` (`entity`,`code`,`lang`) |
| 3672 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3672 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3673 |
|
3673 |
|
| 3674 |
-- |
3674 |
-- |
| 3675 |
-- Table structure for table 'audio_alerts' |
3675 |
-- Table structure for table 'audio_alerts' |
|
Lines 3683-3689
CREATE TABLE audio_alerts (
Link Here
|
| 3683 |
sound varchar(255) NOT NULL, |
3683 |
sound varchar(255) NOT NULL, |
| 3684 |
PRIMARY KEY (id), |
3684 |
PRIMARY KEY (id), |
| 3685 |
KEY precedence (precedence) |
3685 |
KEY precedence (precedence) |
| 3686 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3686 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3687 |
|
3687 |
|
| 3688 |
-- |
3688 |
-- |
| 3689 |
-- Table structure for table 'edifact_ean' |
3689 |
-- Table structure for table 'edifact_ean' |
|
Lines 3697-3703
CREATE TABLE IF NOT EXISTS edifact_ean (
Link Here
|
| 3697 |
ean VARCHAR(15) NOT NULL, |
3697 |
ean VARCHAR(15) NOT NULL, |
| 3698 |
id_code_qualifier VARCHAR(3) NOT NULL DEFAULT '14', |
3698 |
id_code_qualifier VARCHAR(3) NOT NULL DEFAULT '14', |
| 3699 |
CONSTRAINT efk_branchcode FOREIGN KEY ( branchcode ) REFERENCES branches ( branchcode ) |
3699 |
CONSTRAINT efk_branchcode FOREIGN KEY ( branchcode ) REFERENCES branches ( branchcode ) |
| 3700 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3700 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3701 |
|
3701 |
|
| 3702 |
-- |
3702 |
-- |
| 3703 |
-- Table structure for table `courses` |
3703 |
-- Table structure for table `courses` |
|
Lines 3720-3726
CREATE TABLE `courses` (
Link Here
|
| 3720 |
`enabled` enum('yes','no') NOT NULL DEFAULT 'yes', -- determines whether the course is active |
3720 |
`enabled` enum('yes','no') NOT NULL DEFAULT 'yes', -- determines whether the course is active |
| 3721 |
`timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, |
3721 |
`timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, |
| 3722 |
PRIMARY KEY (`course_id`) |
3722 |
PRIMARY KEY (`course_id`) |
| 3723 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3723 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3724 |
|
3724 |
|
| 3725 |
-- |
3725 |
-- |
| 3726 |
-- Table structure for table `course_instructors` |
3726 |
-- Table structure for table `course_instructors` |
|
Lines 3736-3742
CREATE TABLE `course_instructors` (
Link Here
|
| 3736 |
`borrowernumber` int(11) NOT NULL, -- foreign key to link to borrowers.borrowernumber for instructor information |
3736 |
`borrowernumber` int(11) NOT NULL, -- foreign key to link to borrowers.borrowernumber for instructor information |
| 3737 |
PRIMARY KEY (`course_id`,`borrowernumber`), |
3737 |
PRIMARY KEY (`course_id`,`borrowernumber`), |
| 3738 |
KEY `borrowernumber` (`borrowernumber`) |
3738 |
KEY `borrowernumber` (`borrowernumber`) |
| 3739 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3739 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3740 |
|
3740 |
|
| 3741 |
-- |
3741 |
-- |
| 3742 |
-- Constraints for table `course_instructors` |
3742 |
-- Constraints for table `course_instructors` |
|
Lines 3766-3772
CREATE TABLE `course_items` (
Link Here
|
| 3766 |
PRIMARY KEY (`ci_id`), |
3766 |
PRIMARY KEY (`ci_id`), |
| 3767 |
UNIQUE KEY `itemnumber` (`itemnumber`), |
3767 |
UNIQUE KEY `itemnumber` (`itemnumber`), |
| 3768 |
KEY `holdingbranch` (`holdingbranch`) |
3768 |
KEY `holdingbranch` (`holdingbranch`) |
| 3769 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3769 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3770 |
|
3770 |
|
| 3771 |
-- |
3771 |
-- |
| 3772 |
-- Constraints for table `course_items` |
3772 |
-- Constraints for table `course_items` |
|
Lines 3793-3799
CREATE TABLE `course_reserves` (
Link Here
|
| 3793 |
PRIMARY KEY (`cr_id`), |
3793 |
PRIMARY KEY (`cr_id`), |
| 3794 |
UNIQUE KEY `pseudo_key` (`course_id`,`ci_id`), |
3794 |
UNIQUE KEY `pseudo_key` (`course_id`,`ci_id`), |
| 3795 |
KEY `course_id` (`course_id`) |
3795 |
KEY `course_id` (`course_id`) |
| 3796 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3796 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3797 |
|
3797 |
|
| 3798 |
-- |
3798 |
-- |
| 3799 |
-- Constraints for table `course_reserves` |
3799 |
-- Constraints for table `course_reserves` |
|
Lines 3823-3829
CREATE TABLE `hold_fill_targets` (
Link Here
|
| 3823 |
REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
3823 |
REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3824 |
CONSTRAINT `hold_fill_targets_ibfk_4` FOREIGN KEY (`source_branchcode`) |
3824 |
CONSTRAINT `hold_fill_targets_ibfk_4` FOREIGN KEY (`source_branchcode`) |
| 3825 |
REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
3825 |
REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3826 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3826 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3827 |
|
3827 |
|
| 3828 |
-- |
3828 |
-- |
| 3829 |
-- Table structure for table `housebound_profile` |
3829 |
-- Table structure for table `housebound_profile` |
|
Lines 3844-3850
CREATE TABLE `housebound_profile` (
Link Here
|
| 3844 |
FOREIGN KEY (`borrowernumber`) |
3844 |
FOREIGN KEY (`borrowernumber`) |
| 3845 |
REFERENCES `borrowers` (`borrowernumber`) |
3845 |
REFERENCES `borrowers` (`borrowernumber`) |
| 3846 |
ON UPDATE CASCADE ON DELETE CASCADE |
3846 |
ON UPDATE CASCADE ON DELETE CASCADE |
| 3847 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3847 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3848 |
|
3848 |
|
| 3849 |
-- |
3849 |
-- |
| 3850 |
-- Table structure for table `housebound_visit` |
3850 |
-- Table structure for table `housebound_visit` |
|
Lines 3871-3877
CREATE TABLE `housebound_visit` (
Link Here
|
| 3871 |
FOREIGN KEY (`deliverer_brwnumber`) |
3871 |
FOREIGN KEY (`deliverer_brwnumber`) |
| 3872 |
REFERENCES `borrowers` (`borrowernumber`) |
3872 |
REFERENCES `borrowers` (`borrowernumber`) |
| 3873 |
ON UPDATE CASCADE ON DELETE CASCADE |
3873 |
ON UPDATE CASCADE ON DELETE CASCADE |
| 3874 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3874 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3875 |
|
3875 |
|
| 3876 |
-- |
3876 |
-- |
| 3877 |
-- Table structure for table `housebound_role` |
3877 |
-- Table structure for table `housebound_role` |
|
Lines 3887-3893
CREATE TABLE IF NOT EXISTS `housebound_role` (
Link Here
|
| 3887 |
FOREIGN KEY (`borrowernumber_id`) |
3887 |
FOREIGN KEY (`borrowernumber_id`) |
| 3888 |
REFERENCES `borrowers` (`borrowernumber`) |
3888 |
REFERENCES `borrowers` (`borrowernumber`) |
| 3889 |
ON UPDATE CASCADE ON DELETE CASCADE |
3889 |
ON UPDATE CASCADE ON DELETE CASCADE |
| 3890 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3890 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3891 |
|
3891 |
|
| 3892 |
-- |
3892 |
-- |
| 3893 |
-- Table structure for table 'article_requests' |
3893 |
-- Table structure for table 'article_requests' |
|
Lines 3899-3905
CREATE TABLE `article_requests` (
Link Here
|
| 3899 |
`borrowernumber` int(11) NOT NULL, |
3899 |
`borrowernumber` int(11) NOT NULL, |
| 3900 |
`biblionumber` int(11) NOT NULL, |
3900 |
`biblionumber` int(11) NOT NULL, |
| 3901 |
`itemnumber` int(11) DEFAULT NULL, |
3901 |
`itemnumber` int(11) DEFAULT NULL, |
| 3902 |
`branchcode` varchar(10) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT NULL, |
3902 |
`branchcode` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL, |
| 3903 |
`title` text, |
3903 |
`title` text, |
| 3904 |
`author` text, |
3904 |
`author` text, |
| 3905 |
`volume` text, |
3905 |
`volume` text, |
|
Lines 3921-3927
CREATE TABLE `article_requests` (
Link Here
|
| 3921 |
CONSTRAINT `article_requests_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
3921 |
CONSTRAINT `article_requests_ibfk_2` FOREIGN KEY (`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3922 |
CONSTRAINT `article_requests_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
3922 |
CONSTRAINT `article_requests_ibfk_3` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE SET NULL ON UPDATE CASCADE, |
| 3923 |
CONSTRAINT `article_requests_ibfk_4` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE SET NULL ON UPDATE CASCADE |
3923 |
CONSTRAINT `article_requests_ibfk_4` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE SET NULL ON UPDATE CASCADE |
| 3924 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3924 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3925 |
|
3925 |
|
| 3926 |
-- |
3926 |
-- |
| 3927 |
-- Table structure for table `biblio_metadata` |
3927 |
-- Table structure for table `biblio_metadata` |
|
Lines 3939-3945
CREATE TABLE biblio_metadata (
Link Here
|
| 3939 |
UNIQUE KEY `biblio_metadata_uniq_key` (`biblionumber`,`format`,`marcflavour`), |
3939 |
UNIQUE KEY `biblio_metadata_uniq_key` (`biblionumber`,`format`,`marcflavour`), |
| 3940 |
CONSTRAINT `record_metadata_fk_1` FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
3940 |
CONSTRAINT `record_metadata_fk_1` FOREIGN KEY (biblionumber) REFERENCES biblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3941 |
KEY `timestamp` (`timestamp`) |
3941 |
KEY `timestamp` (`timestamp`) |
| 3942 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3942 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3943 |
|
3943 |
|
| 3944 |
-- |
3944 |
-- |
| 3945 |
-- Table structure for table `deletedbiblio_metadata` |
3945 |
-- Table structure for table `deletedbiblio_metadata` |
|
Lines 3957-3963
CREATE TABLE deletedbiblio_metadata (
Link Here
|
| 3957 |
UNIQUE KEY `deletedbiblio_metadata_uniq_key` (`biblionumber`,`format`,`marcflavour`), |
3957 |
UNIQUE KEY `deletedbiblio_metadata_uniq_key` (`biblionumber`,`format`,`marcflavour`), |
| 3958 |
CONSTRAINT `deletedrecord_metadata_fk_1` FOREIGN KEY (biblionumber) REFERENCES deletedbiblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
3958 |
CONSTRAINT `deletedrecord_metadata_fk_1` FOREIGN KEY (biblionumber) REFERENCES deletedbiblio (biblionumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3959 |
KEY `timestamp` (`timestamp`) |
3959 |
KEY `timestamp` (`timestamp`) |
| 3960 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3960 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3961 |
|
3961 |
|
| 3962 |
-- |
3962 |
-- |
| 3963 |
-- Table structure for table 'club_templates' |
3963 |
-- Table structure for table 'club_templates' |
|
Lines 3976-3982
CREATE TABLE IF NOT EXISTS club_templates (
Link Here
|
| 3976 |
PRIMARY KEY (id), |
3976 |
PRIMARY KEY (id), |
| 3977 |
KEY ct_branchcode (branchcode), |
3977 |
KEY ct_branchcode (branchcode), |
| 3978 |
CONSTRAINT `club_templates_ibfk_1` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
3978 |
CONSTRAINT `club_templates_ibfk_1` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE |
| 3979 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
3979 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 3980 |
|
3980 |
|
| 3981 |
-- |
3981 |
-- |
| 3982 |
-- Table structure for table 'clubs' |
3982 |
-- Table structure for table 'clubs' |
|
Lines 3997-4003
CREATE TABLE IF NOT EXISTS clubs (
Link Here
|
| 3997 |
KEY branchcode (branchcode), |
3997 |
KEY branchcode (branchcode), |
| 3998 |
CONSTRAINT clubs_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE, |
3998 |
CONSTRAINT clubs_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 3999 |
CONSTRAINT clubs_ibfk_2 FOREIGN KEY (branchcode) REFERENCES branches (branchcode) |
3999 |
CONSTRAINT clubs_ibfk_2 FOREIGN KEY (branchcode) REFERENCES branches (branchcode) |
| 4000 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4000 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4001 |
|
4001 |
|
| 4002 |
-- |
4002 |
-- |
| 4003 |
-- Table structure for table 'club_enrollments' |
4003 |
-- Table structure for table 'club_enrollments' |
|
Lines 4019-4025
CREATE TABLE IF NOT EXISTS club_enrollments (
Link Here
|
| 4019 |
CONSTRAINT club_enrollments_ibfk_1 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE, |
4019 |
CONSTRAINT club_enrollments_ibfk_1 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 4020 |
CONSTRAINT club_enrollments_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
4020 |
CONSTRAINT club_enrollments_ibfk_2 FOREIGN KEY (borrowernumber) REFERENCES borrowers (borrowernumber) ON DELETE CASCADE ON UPDATE CASCADE, |
| 4021 |
CONSTRAINT club_enrollments_ibfk_3 FOREIGN KEY (branchcode) REFERENCES branches (branchcode) ON DELETE SET NULL ON UPDATE CASCADE |
4021 |
CONSTRAINT club_enrollments_ibfk_3 FOREIGN KEY (branchcode) REFERENCES branches (branchcode) ON DELETE SET NULL ON UPDATE CASCADE |
| 4022 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4022 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4023 |
|
4023 |
|
| 4024 |
-- |
4024 |
-- |
| 4025 |
-- Table structure for table 'club_template_enrollment_fields' |
4025 |
-- Table structure for table 'club_template_enrollment_fields' |
|
Lines 4034-4040
CREATE TABLE IF NOT EXISTS club_template_enrollment_fields (
Link Here
|
| 4034 |
PRIMARY KEY (id), |
4034 |
PRIMARY KEY (id), |
| 4035 |
KEY club_template_id (club_template_id), |
4035 |
KEY club_template_id (club_template_id), |
| 4036 |
CONSTRAINT club_template_enrollment_fields_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE |
4036 |
CONSTRAINT club_template_enrollment_fields_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE |
| 4037 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4037 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4038 |
|
4038 |
|
| 4039 |
-- |
4039 |
-- |
| 4040 |
-- Table structure for table 'club_enrollment_fields' |
4040 |
-- Table structure for table 'club_enrollment_fields' |
|
Lines 4050-4056
CREATE TABLE IF NOT EXISTS club_enrollment_fields (
Link Here
|
| 4050 |
KEY club_template_enrollment_field_id (club_template_enrollment_field_id), |
4050 |
KEY club_template_enrollment_field_id (club_template_enrollment_field_id), |
| 4051 |
CONSTRAINT club_enrollment_fields_ibfk_1 FOREIGN KEY (club_enrollment_id) REFERENCES club_enrollments (id) ON DELETE CASCADE ON UPDATE CASCADE, |
4051 |
CONSTRAINT club_enrollment_fields_ibfk_1 FOREIGN KEY (club_enrollment_id) REFERENCES club_enrollments (id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 4052 |
CONSTRAINT club_enrollment_fields_ibfk_2 FOREIGN KEY (club_template_enrollment_field_id) REFERENCES club_template_enrollment_fields (id) ON DELETE CASCADE ON UPDATE CASCADE |
4052 |
CONSTRAINT club_enrollment_fields_ibfk_2 FOREIGN KEY (club_template_enrollment_field_id) REFERENCES club_template_enrollment_fields (id) ON DELETE CASCADE ON UPDATE CASCADE |
| 4053 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4053 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4054 |
|
4054 |
|
| 4055 |
-- |
4055 |
-- |
| 4056 |
-- Table structure for table 'club_template_fields' |
4056 |
-- Table structure for table 'club_template_fields' |
|
Lines 4065-4071
CREATE TABLE IF NOT EXISTS club_template_fields (
Link Here
|
| 4065 |
PRIMARY KEY (id), |
4065 |
PRIMARY KEY (id), |
| 4066 |
KEY club_template_id (club_template_id), |
4066 |
KEY club_template_id (club_template_id), |
| 4067 |
CONSTRAINT club_template_fields_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE |
4067 |
CONSTRAINT club_template_fields_ibfk_1 FOREIGN KEY (club_template_id) REFERENCES club_templates (id) ON DELETE CASCADE ON UPDATE CASCADE |
| 4068 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4068 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4069 |
|
4069 |
|
| 4070 |
-- |
4070 |
-- |
| 4071 |
-- Table structure for table 'club_fields' |
4071 |
-- Table structure for table 'club_fields' |
|
Lines 4081-4087
CREATE TABLE IF NOT EXISTS club_fields (
Link Here
|
| 4081 |
KEY club_id (club_id), |
4081 |
KEY club_id (club_id), |
| 4082 |
CONSTRAINT club_fields_ibfk_3 FOREIGN KEY (club_template_field_id) REFERENCES club_template_fields (id) ON DELETE CASCADE ON UPDATE CASCADE, |
4082 |
CONSTRAINT club_fields_ibfk_3 FOREIGN KEY (club_template_field_id) REFERENCES club_template_fields (id) ON DELETE CASCADE ON UPDATE CASCADE, |
| 4083 |
CONSTRAINT club_fields_ibfk_4 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE |
4083 |
CONSTRAINT club_fields_ibfk_4 FOREIGN KEY (club_id) REFERENCES clubs (id) ON DELETE CASCADE ON UPDATE CASCADE |
| 4084 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4084 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4085 |
|
4085 |
|
| 4086 |
-- |
4086 |
-- |
| 4087 |
-- Table structure for table `illrequests` |
4087 |
-- Table structure for table `illrequests` |
|
Lines 4114-4120
CREATE TABLE illrequests (
Link Here
|
| 4114 |
FOREIGN KEY (`branchcode`) |
4114 |
FOREIGN KEY (`branchcode`) |
| 4115 |
REFERENCES `branches` (`branchcode`) |
4115 |
REFERENCES `branches` (`branchcode`) |
| 4116 |
ON UPDATE CASCADE ON DELETE CASCADE |
4116 |
ON UPDATE CASCADE ON DELETE CASCADE |
| 4117 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4117 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4118 |
|
4118 |
|
| 4119 |
-- |
4119 |
-- |
| 4120 |
-- Table structure for table `illrequestattributes` |
4120 |
-- Table structure for table `illrequestattributes` |
|
Lines 4125-4136
CREATE TABLE illrequestattributes (
Link Here
|
| 4125 |
illrequest_id bigint(20) unsigned NOT NULL, -- ILL request number |
4125 |
illrequest_id bigint(20) unsigned NOT NULL, -- ILL request number |
| 4126 |
type varchar(200) NOT NULL, -- API ILL property name |
4126 |
type varchar(200) NOT NULL, -- API ILL property name |
| 4127 |
value text NOT NULL, -- API ILL property value |
4127 |
value text NOT NULL, -- API ILL property value |
| 4128 |
PRIMARY KEY (`illrequest_id`,`type`), |
4128 |
PRIMARY KEY (`illrequest_id`, `type` (191)), |
| 4129 |
CONSTRAINT `illrequestattributes_ifk` |
4129 |
CONSTRAINT `illrequestattributes_ifk` |
| 4130 |
FOREIGN KEY (illrequest_id) |
4130 |
FOREIGN KEY (illrequest_id) |
| 4131 |
REFERENCES `illrequests` (`illrequest_id`) |
4131 |
REFERENCES `illrequests` (`illrequest_id`) |
| 4132 |
ON UPDATE CASCADE ON DELETE CASCADE |
4132 |
ON UPDATE CASCADE ON DELETE CASCADE |
| 4133 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |
4133 |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; |
| 4134 |
|
4134 |
|
| 4135 |
-- |
4135 |
-- |
| 4136 |
-- Table structure for table 'library_groups' |
4136 |
-- Table structure for table 'library_groups' |
| 4137 |
- |
|
|