diff --git a/lib/db/upgrade.php b/lib/db/upgrade.php index 02047847e5d..f636b6046f0 100644 --- a/lib/db/upgrade.php +++ b/lib/db/upgrade.php @@ -1578,16 +1578,19 @@ function xmldb_main_upgrade($oldversion=0) { build_context_rel(); } - if ($result && $oldversion < 2007080201) { + if ($result && $oldversion < 2007080202) { /// Define index tagiditem (not unique) to be dropped form tag_instance $table = new XMLDBTable('tag_instance'); $index = new XMLDBIndex('tagiditem'); + $index->setAttributes(XMLDB_INDEX_NOTUNIQUE, array('tagid', 'itemtype', 'itemid')); /// Launch drop index tagiditem drop_index($table, $index); /// Define index tagiditem (unique) to be added to tag_instance + $table = new XMLDBTable('tag_instance'); + $index = new XMLDBIndex('tagiditem'); $index->setAttributes(XMLDB_INDEX_UNIQUE, array('tagid', 'itemtype', 'itemid')); /// Launch add index tagiditem diff --git a/version.php b/version.php index 7fc6b4980cc..c9d1123b1a5 100644 --- a/version.php +++ b/version.php @@ -6,7 +6,7 @@ // This is compared against the values stored in the database to determine // whether upgrades should be performed (see lib/db/*.php) - $version = 2007080201; // YYYYMMDD = date + $version = 2007080202; // YYYYMMDD = date // XY = increments within a single day $release = '1.9 dev'; // Human-friendly version name