From eb2658e03a0dde981a61017173c3778b8f8f3240 Mon Sep 17 00:00:00 2001 From: nicolasconnault Date: Thu, 26 Apr 2007 05:40:35 +0000 Subject: [PATCH] MDL-9506 Changed grade_calculations.usermodified type to null from non-null. --- lib/db/install.xml | 4 ++-- lib/db/upgrade.php | 10 ++++++++++ version.php | 2 +- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/lib/db/install.xml b/lib/db/install.xml index dec9959b3d..2d238b9dac 100644 --- a/lib/db/install.xml +++ b/lib/db/install.xml @@ -472,7 +472,7 @@ - + @@ -1291,7 +1291,7 @@ - + diff --git a/lib/db/upgrade.php b/lib/db/upgrade.php index 88cf92b339..d94197eedb 100644 --- a/lib/db/upgrade.php +++ b/lib/db/upgrade.php @@ -1019,6 +1019,16 @@ function xmldb_main_upgrade($oldversion=0) { $result = $result && add_field($table, $field); } + if ($result && $oldversion < 2007042601) { + + /// Changing nullability of field usermodified on table grade_calculations to null + $table = new XMLDBTable('grade_calculations'); + $field = new XMLDBField('usermodified'); + $field->setAttributes(XMLDB_TYPE_INTEGER, '10', XMLDB_UNSIGNED, null, null, null, null, null, 'timemodified'); + + /// Launch change of nullability for field usermodified + $result = $result && change_field_notnull($table, $field); + } return $result; } diff --git a/version.php b/version.php index d2c5a718d8..aa3f3f92e0 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 = 2007042600; // YYYYMMDD = date + $version = 2007042601; // YYYYMMDD = date // XY = increments within a single day $release = '1.9 dev'; // Human-friendly version name -- 2.39.5