diff options
author | Marc Delisle <marc@infomarc.info> | 2014-04-07 21:09:32 +0400 |
---|---|---|
committer | Marc Delisle <marc@infomarc.info> | 2014-04-07 21:09:32 +0400 |
commit | 507fa83e7f8dea217c71bae73368da8c3336a1da (patch) | |
tree | 351c0ab0cb39f446230dca3c9361c246db912fd9 | |
parent | 7a11533350817fb4575a228d446c166be99c067e (diff) | |
parent | 81ed4c9c83bad24551696593c99c2b19b79b39e8 (diff) |
Merge branch 'QA_4_1'
-rw-r--r-- | ChangeLog | 1 | ||||
-rw-r--r-- | libraries/Table.class.php | 6 | ||||
-rw-r--r-- | test/classes/PMA_Table_test.php | 2 |
3 files changed, 7 insertions, 2 deletions
@@ -56,6 +56,7 @@ phpMyAdmin - ChangeLog - bug #4347 Fixed PHP Parse error in Advisor - bug #4350 Deleting the DB if it is renamed by the same name - bug #4353 makeProfilingChart is not defined +- bug #4355 Precision specifier for DOUBLE type is truncated 4.1.12.0 (2014-03-27) - bug #4334 Add event : datepicker won't open diff --git a/libraries/Table.class.php b/libraries/Table.class.php index 26911c8c49..562564c6b5 100644 --- a/libraries/Table.class.php +++ b/libraries/Table.class.php @@ -428,10 +428,14 @@ class PMA_Table // allow the possibility of a length for TIME, DATETIME and TIMESTAMP // (will work on MySQL >= 5.6.4) + // + // MySQL permits a non-standard syntax for FLOAT and DOUBLE, + // see http://dev.mysql.com/doc/refman/5.5/en/floating-point-types.html + // if ($length != '' && ! preg_match( '@^(DATE|TINYBLOB|TINYTEXT|BLOB|TEXT|' - . 'MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT|SERIAL|BOOLEAN|DOUBLE|FLOAT|UUID)$@i', + . 'MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT|SERIAL|BOOLEAN|UUID)$@i', $type ) ) { diff --git a/test/classes/PMA_Table_test.php b/test/classes/PMA_Table_test.php index e5c4cc316b..40e91a9bf5 100644 --- a/test/classes/PMA_Table_test.php +++ b/test/classes/PMA_Table_test.php @@ -506,7 +506,7 @@ class PMA_Table_Test extends PHPUnit_Framework_TestCase $field_primary, $move_to ); $this->assertEquals( - "`PMA_name` DOUBLE PMA_attribute NULL DEFAULT '12' " + "`PMA_name` DOUBLE(12) PMA_attribute NULL DEFAULT '12' " . "AUTO_INCREMENT COMMENT 'PMA_comment' FIRST", $query ); |