From 9ea4ce42865558bc5615be596c8e11d29cc8d684 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Mon, 12 May 2008 08:32:47 -0500 Subject: [PATCH] kohabug 2076: more reconciliation of DB schema (DB rev 080) Adjustments to updatedatabase.pl to help ensure that a DB upgraded from 2.2.9, 3.0-alpha, or 3.0-beta has a schema identical to a fresh installation. The changes to the following columns and indexes are to default values, field widths, position relative to other columns or index names. virtualshelfcontents.biblionumber virtualshelfcontents_ibfk_1 (virtualshelfcontents) shelfcontents_ibfk_2 (virtualshelfcontents) sessions.id deletedbiblioitems.marc branchcategories.categorycode branchrelations.categorycode items.damaged deleteditems.notforloan deleteditems.damaged deleteditems.itemlost deleteditems.wthdrawn currency.symbol subscription.numberlength subscription.weeklength serialidx (serialitems) items.more_subfields_xml z3950servers.type deleteditems.more_subfields_xml opac_news.lang labels_conf.formatstring The following missing columns were added: deletedbiblioitems.marcxml deleteditems.itype The 080 DB rev is specifically for syncing the schema for users of 3.0-alpha, 3.0-beta, and 3.0-beta2, and should be a no-op for anybody who has followed git HEAD for the past few months: subscription.monthlength deleteditems.marc aqbooksellers.name NOTE: this patch does not handle the case of syncing the DB of a developer or user who has been following git HEAD since before 3.0-alpha. Signed-off-by: Joshua Ferraro --- installer/data/mysql/updatedatabase.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 7f6324cb8b..28be9a2965 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -1501,6 +1501,8 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { SetVersion ($DBversion); } + + $DBversion = "3.00.00.080"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("ALTER TABLE subscription CHANGE monthlength monthlength int(11) default '0'"); -- 2.39.5