View | Details | Raw Unified | Return to bug 18606
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/rotatingCollections.perl (+7 lines)
Line 0 Link Here
1
$DBversion = 'XXX';  # will be replaced by RM
2
if( CheckVersion( $DBversion ) ) {
3
    $dbh->do( "ALTER TABLE collections_tracking ADD CONSTRAINT collections_tracking_ibfk_1 FOREIGN KEY (colId) REFERENCES collections (colId) ON DELETE CASCADE ON UPDATE CASCADE" );    $dbh->do( "ALTER TABLE collections_tracking ADD CONSTRAINT collections_tracking_ibfk_2 FOREIGN KEY (itemnumber) REFERENCES items (itemnumber) ON DELETE CASCADE ON UPDATE CASCADE" );
4
5
    SetVersion( $DBversion );
6
    print "Upgrade to $DBversion done (Bug XXXXX - Rotating collections objects)\n";
7
}
(-)a/installer/data/mysql/kohastructure.sql (-13 / +18 lines)
Lines 328-345 ALTER TABLE `collections` Link Here
328
  ADD CONSTRAINT `collections_ibfk_1` FOREIGN KEY (`colBranchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE;
328
  ADD CONSTRAINT `collections_ibfk_1` FOREIGN KEY (`colBranchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE;
329
329
330
--
330
--
331
-- Table: collections_tracking
332
--
333
334
DROP TABLE IF EXISTS collections_tracking;
335
CREATE TABLE collections_tracking (
336
  collections_tracking_id integer(11) NOT NULL auto_increment,
337
  colId integer(11) NOT NULL DEFAULT 0 comment 'collections.colId',
338
  itemnumber integer(11) NOT NULL DEFAULT 0 comment 'items.itemnumber',
339
  PRIMARY KEY (collections_tracking_id)
340
) ENGINE=InnoDB  DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
341
342
--
343
-- Table structure for table `branch_borrower_circ_rules`
331
-- Table structure for table `branch_borrower_circ_rules`
344
--
332
--
345
333
Lines 970-975 CREATE TABLE `itemtypes` ( -- defines the item types Link Here
970
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
958
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
971
959
972
--
960
--
961
-- Table: collections_tracking
962
--
963
964
DROP TABLE IF EXISTS collections_tracking;
965
CREATE TABLE collections_tracking (
966
  collections_tracking_id integer(11) NOT NULL auto_increment,
967
  colId integer(11) NOT NULL DEFAULT 0 comment 'collections.colId',
968
  itemnumber integer(11) NOT NULL DEFAULT 0 comment 'items.itemnumber',
969
  PRIMARY KEY (collections_tracking_id)
970
) ENGINE=InnoDB  DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
971
972
ALTER TABLE `collections_tracking`
973
  ADD CONSTRAINT `collections_tracking_ibfk_1` FOREIGN KEY (`colId`) REFERENCES `collections` (`colId`) ON DELETE CASCADE ON UPDATE CASCADE;
974
975
ALTER TABLE `collections_tracking`
976
  ADD CONSTRAINT `collections_tracking_ibfk_2` FOREIGN KEY (`itemnumber`) REFERENCES `items` (`itemnumber`) ON DELETE CASCADE ON UPDATE CASCADE;
977
978
--
973
-- Table structure for table `default_branch_item_rules`
979
-- Table structure for table `default_branch_item_rules`
974
--
980
--
975
981
976
- 

Return to bug 18606