Koha/installer/data/mysql/db_revs/210600011.pl
Jonathan Druart 64ccbdb8f2 Bug 25078: Move DB revs up to 21.06.00.016
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2021-08-16 11:55:56 +02:00

39 lines
824 B
Perl

use Modern::Perl;
{
bug_number => "28567",
description => "Set to NULL empty branches fields",
up => sub {
my ($args) = @_;
my $dbh = $args->{dbh};
my @fields = qw(
branchname
branchaddress1
branchaddress2
branchaddress3
branchzip
branchcity
branchstate
branchcountry
branchphone
branchfax
branchemail
branchillemail
branchreplyto
branchreturnpath
branchurl
branchip
branchnotes
opac_info
marcorgcode
);
for my $f ( @fields ) {
$dbh->do(qq{
UPDATE branches
SET $f = NULL
WHERE $f = ""
});
}
},
}