@@ -, +, @@ --- .../mysql/atomicupdate/bug_31948_tmp_holdsqueue.pl | 13 +++++++++++++ installer/data/mysql/kohastructure.sql | 1 + 2 files changed, 14 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_31948_tmp_holdsqueue.pl --- a/installer/data/mysql/atomicupdate/bug_31948_tmp_holdsqueue.pl +++ a/installer/data/mysql/atomicupdate/bug_31948_tmp_holdsqueue.pl @@ -0,0 +1,13 @@ +use Modern::Perl; + +return { + bug_number => "31948", + description => "Add timestamp to tmp_holdsqueue table", + up => sub { + my ($args) = @_; + my ($dbh, $out) = @$args{qw(dbh out)}; + + $dbh->do(q{ALTER TABLE `tmp_holdsqueue` ADD `timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP AFTER item_level_request}); + say $out ""; + }, +}; --- a/installer/data/mysql/kohastructure.sql +++ a/installer/data/mysql/kohastructure.sql @@ -5382,6 +5382,7 @@ CREATE TABLE `tmp_holdsqueue` ( `pickbranch` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT NULL, `notes` mediumtext COLLATE utf8mb4_unicode_ci DEFAULT NULL, `item_level_request` tinyint(4) NOT NULL DEFAULT 0, + `timestamp` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp() COMMENT 'date and time this entry as added/last updated', KEY `tmp_holdsqueue_ibfk_1` (`itemnumber`), KEY `tmp_holdsqueue_ibfk_2` (`biblionumber`), KEY `tmp_holdsqueue_ibfk_3` (`borrowernumber`), --