Bug 38436: Rename columns_settings.columnname in DB
Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
This commit is contained in:
parent
42df19b3e1
commit
4e12775e4f
|
|
@ -0,0 +1,18 @@
|
|||
use Modern::Perl;
|
||||
use Koha::Installer::Output qw(say_warning say_success say_info);
|
||||
|
||||
return {
|
||||
bug_number => "38436",
|
||||
description => "Adjust column names for holdings tables",
|
||||
up => sub {
|
||||
my ($args) = @_;
|
||||
my ( $dbh, $out ) = @$args{qw(dbh out)};
|
||||
|
||||
say $dbh->do(q{
|
||||
UPDATE columns_settings
|
||||
SET columnname = REGEXP_REPLACE(columnname, '.*holdings_', '')
|
||||
WHERE module="catalogue" AND page="detail" AND ( tablename="holdings_table" OR tablename="otherholdings_table")
|
||||
});
|
||||
say_success( $out, "Column names renamed" );
|
||||
},
|
||||
};
|
||||
Loading…
Reference in New Issue