Details
Description
I have a column in an entity, defined as "float" type.
When I run my phpunit tests (which are defined to use sqlite, whereas my production and development environment uses mysql), I get the following exception:
Doctrine\DBAL\DBALException: Unknown database type double precision requested, Doctrine\DBAL\Platforms\SqlitePlatform may not support it
Looking at AbstractPlatform.php, line 1972, function "getFloatDeclarationSQL" returns 'DOUBLE PRECISION'.
Where other platforms have in their "initializeDoctrineTypeMappings" method a mapping such as:
'double precision' => 'float',
, SqlitePlatform.php doesn't have such a mapping.
Activity
Doron Gutman
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Environment |
Ubuntu Linux 11.04 PHP 5.3.5 |
Steven Rosato
made changes -
| Attachment | 0001-Fix-for-DBAL-158-where-double-precision-was-not-work.patch [ 11070 ] |
Benjamin Eberlei
made changes -
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Fix Version/s | 2.1.4 [ 10167 ] | |
| Resolution | Fixed [ 1 ] |
Benjamin Eberlei
made changes -
| Workflow | jira [ 12966 ] | jira-feedback2 [ 17731 ] |
Benjamin Eberlei
made changes -
| Workflow | jira-feedback2 [ 17731 ] | jira-feedback3 [ 20086 ] |