Patch for Bug #449858 from Ignacio Vazquez-Abrams. First patch used, not second one.

This commit is contained in:
Robin Johnson
2001-08-14 17:48:42 +00:00
parent c8e110a40b
commit 4ccadfe6b2
2 changed files with 24 additions and 3 deletions

View File

@@ -5,6 +5,9 @@ phpMyAdmin - Changelog
$Id$
$Source$
2001-08-14 Robin Johnson <robbat2@orbis-terrarum.net>
* Patch for Bug #449858 from Ignacio Vazquez-Abrams. First patch used, not second one.
2001-08-10 Robin Johnson <robbat2@orbis-terrarum.net>
* BUG #448206, Support of table aliases - fixed, added expand_sql_query in lib.inc.php3 and a loop in db_readdump.php3 to apply it

View File

@@ -28,9 +28,27 @@ if (isset($submit)) {
$query = '';
}
$query .= ' ' . backquote($field_orig[0]) . ' ' . backquote($field_name[0]) . ' ' . $field_type[0] . ' ';
if ($field_length[0] != '') {
$query .= '(' . $field_length[0] . ') ';
}
// Some field types shouldn't have lengths
switch (strtoupper($field_type[0]))
{
case 'DATE':
case 'DATETIME':
case 'TIME':
case 'TINYBLOB':
case 'TINYTEXT':
case 'BLOB':
case 'TEXT':
case 'MEDIUMBLOB':
case 'MEDIUMTEXT':
case 'LONGBLOB':
case 'LONGTEXT':
break;
default:
if ($field_length[0] != '') {
$query .= '(' . $field_length[0] . ') ';
};
};
if ($field_attribute[0] != '') {
$query .= $field_attribute[0] . ' ';
}