Bug 30565: DBRev 21.12.00.040
[koha.git] / installer / data / mysql / db_revs / 211200010.pl
1 use Modern::Perl;
2
3 return {
4     bug_number => "21729",
5     description => "Add new column reserves.patron_expiration_date",
6     up => sub {
7         my ($args) = @_;
8         my ($dbh, $out) = @$args{qw(dbh out)};
9         unless( column_exists('reserves', 'patron_expiration_date') ) {
10             $dbh->do(q{
11                 ALTER TABLE reserves
12                 ADD COlUMN patron_expiration_date date DEFAULT NULL COMMENT 'the date the hold expires - usually the date entered by the patron to say they don''t need the hold after a certain date'
13                 AFTER expirationdate
14             });
15         }
16         unless( column_exists('old_reserves', 'patron_expiration_date') ) {
17             $dbh->do(q{
18                 ALTER TABLE old_reserves
19                 ADD COlUMN patron_expiration_date date DEFAULT NULL COMMENT 'the date the hold expires - usually the date entered by the patron to say they don''t need the hold after a certain date'
20                 AFTER expirationdate
21             });
22         }
23
24     },
25 };