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

(-)a/installer/data/mysql/atomicupdate/bug_29093.pl (+15 lines)
Line 0 Link Here
1
use Modern::Perl;
2
3
return {
4
    bug_number => "29093",
5
    description => "Add column article_requests.toc_request",
6
    up => sub {
7
        my ($args) = @_;
8
        my ($dbh, $out) = @$args{qw(dbh out)};
9
        if( !column_exists('article_requests', 'toc_request') ) {
10
            $dbh->do( q|
11
                ALTER TABLE article_requests ADD COLUMN toc_request tinyint(4) NOT NULL DEFAULT 0 AFTER updated_on
12
            |);
13
        }
14
    },
15
}
(-)a/installer/data/mysql/kohastructure.sql (-1 / +1 lines)
Lines 755-760 CREATE TABLE `article_requests` ( Link Here
755
  `urls` MEDIUMTEXT,
755
  `urls` MEDIUMTEXT,
756
  `created_on` timestamp NULL DEFAULT NULL COMMENT 'Be careful with two timestamps in one table not allowing NULL',
756
  `created_on` timestamp NULL DEFAULT NULL COMMENT 'Be careful with two timestamps in one table not allowing NULL',
757
  `updated_on` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
757
  `updated_on` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
758
  `toc_request` tinyint(4) NOT NULL DEFAULT 0 COMMENT 'borrower requested table of contents',
758
  PRIMARY KEY (`id`),
759
  PRIMARY KEY (`id`),
759
  KEY `borrowernumber` (`borrowernumber`),
760
  KEY `borrowernumber` (`borrowernumber`),
760
  KEY `biblionumber` (`biblionumber`),
761
  KEY `biblionumber` (`biblionumber`),
761
- 

Return to bug 29093