Skip to content

Commit

Permalink
Allow char(0)
Browse files Browse the repository at this point in the history
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@1168 7c3ca157-0c34-0410-bff1-cbf682f78f5c
  • Loading branch information
jakubvrana committed Oct 6, 2009
1 parent fb141cc commit 5c862ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion adminer/include/editing.inc.php
Expand Up @@ -114,7 +114,7 @@ function process_length($length) {
function process_type($field, $collate = "COLLATE") {
global $connection, $enum_length, $unsigned;
return " $field[type]"
. ($field["length"] && !ereg('^date|time$', $field["type"]) ? "(" . process_length($field["length"]) . ")" : "")
. (strlen($field["length"]) && !ereg('^date|time$', $field["type"]) ? "(" . process_length($field["length"]) . ")" : "")
. (ereg('int|float|double|decimal', $field["type"]) && in_array($field["unsigned"], $unsigned) ? " $field[unsigned]" : "")
. (ereg('char|text|enum|set', $field["type"]) && $field["collation"] ? " $collate " . $connection->quote($field["collation"]) : "")
;
Expand Down

0 comments on commit 5c862ba

Please sign in to comment.