1
0
mirror of synced 2025-01-20 23:41:39 +03:00

added 'int' as an alias for 'integer'

This commit is contained in:
zYne 2007-02-04 22:31:55 +00:00
parent 1132282fee
commit f2e19fd9fa

View File

@ -181,6 +181,7 @@ class Doctrine_DataDict_Mysql extends Doctrine_DataDict
} }
return 'LONGBLOB'; return 'LONGBLOB';
case 'integer': case 'integer':
case 'int':
case 'enum': case 'enum':
if (!empty($field['length'])) { if (!empty($field['length'])) {
$length = $field['length']; $length = $field['length'];
@ -211,7 +212,7 @@ class Doctrine_DataDict_Mysql extends Doctrine_DataDict
$length = !empty($field['length']) ? $field['length'] : 18; $length = !empty($field['length']) ? $field['length'] : 18;
return 'DECIMAL(' . $length . ',' . 0 . ')'; //$this->dbh->options['decimal_places'] . ')'; return 'DECIMAL(' . $length . ',' . 0 . ')'; //$this->dbh->options['decimal_places'] . ')';
} }
return ''; throw new Doctrine_DataDict_Exception('Unknown column type.');
} }
/** /**
* Maps a native array description of a field to a MDB2 datatype and length * Maps a native array description of a field to a MDB2 datatype and length