From e4baa0861545a3121c2b6a17ff9e3cb2263ed5e1 Mon Sep 17 00:00:00 2001 From: Lucas Gass Date: Fri, 19 Aug 2022 17:55:32 +0000 Subject: [PATCH] Bug 31212: Add Database update Signed-off-by: Ann Flournoy Signed-off-by: David Nind Signed-off-by: Andrew Fuerste-Henry --- .../data/mysql/atomicupdate/bug_31212_dbrev.pl | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 installer/data/mysql/atomicupdate/bug_31212_dbrev.pl diff --git a/installer/data/mysql/atomicupdate/bug_31212_dbrev.pl b/installer/data/mysql/atomicupdate/bug_31212_dbrev.pl new file mode 100755 index 0000000000..40e790439a --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_31212_dbrev.pl @@ -0,0 +1,17 @@ +use Modern::Perl; + +return { + bug_number => "31212", + description => "Update items.datelastseen and deleteditems.datelastseen to datetime data format", + up => sub { + my ($args) = @_; + my ($dbh, $out) = @$args{qw(dbh out)}; + $dbh->do(q{ + ALTER TABLE `items` MODIFY COLUMN `datelastseen` DATETIME DEFAULT NULL + }); + $dbh->do(q{ + ALTER TABLE `deleteditems` MODIFY COLUMN `datelastseen` DATETIME DEFAULT NULL + }); + say $out "items and deleteditems table updated"; + }, +}; -- 2.30.2