MDL-28032 database - retrofit signed info for decimal/float (improves diffs detection)
authorEloy Lafuente (stronk7) <stronk7@moodle.org>
Fri, 24 Jun 2011 23:09:51 +0000 (01:09 +0200)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Sun, 26 Jun 2011 10:54:16 +0000 (12:54 +0200)
lib/dml/mysqli_native_moodle_database.php

index 243f29d..d2693bf 100644 (file)
@@ -499,7 +499,7 @@ class mysqli_native_moodle_database extends moodle_database {
                 $info->has_default   = is_null($info->default_value) ? false : true;
                 $info->primary_key   = ($rawcolumn->key === 'PRI');
                 $info->binary        = false;
-                $info->unsigned      = null;
+                $info->unsigned      = (stripos($rawcolumn->type, 'unsigned') !== false);
                 $info->auto_increment= false;
                 $info->unique        = null;