http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7263
--- Comment #13 from Magnus Enger <mag...@enger.priv.no> --- But updatedatabase changes the default for a couple of fields: +$DBversion = "3.07.00.XXX"; +if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { + $dbh->do(" + ALTER TABLE `marc_subfield_structure` ADD `maxlength` INT( 4 ) NOT NULL DEFAULT '9999'; + "); + $dbh->do(" + UPDATE `marc_subfield_structure` SET maxlength=24 WHERE tagfield='000'; + "); + $dbh->do(" + UPDATE marc_subfield_structure SET maxlength = IF ((SELECT value FROM systempreferences WHERE variable = 'marcflavour')='MARC21','40','9999') WHERE tagfield='008'; + "); + $dbh->do(" + UPDATE marc_subfield_structure SET maxlength = IF ((SELECT value FROM systempreferences WHERE variable = 'marcflavour')='UNIMARC','36','9999') WHERE tagfield='100'; + "); + print "Upgrade to $DBversion done (Add new field maxlength to marc_subfield_structure)\n"; + SetVersion($DBversion); +} + So all marcflavours on upgraded installations will have maxlength = 24 for 000, while fresh installs will have 9999. And upgraded MARC21 installations will have maxlength = 40 for field 008 while fresh installations will have maxlength = 9999. Might not be much of a problem, but it will lead to subtle differences in installations depending on their history and perhaps a potential for future confusion. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/