Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.1.4, 1.2.0-ALPHA1, 1.2.0-ALPHA2
-
Fix Version/s: 1.2.0-ALPHA3
-
Component/s: Import/Export
-
Labels:None
-
Environment:Windows XP Professional SP3, SQL Server Express 2008
Description
The following yml schema will result in a table with the integer field marked as not null
MyTable:
columns:
intfield:
type: integer
notnull: false
I have traced this back to line 244 in the getIntegerDeclaration function in lib/Doctrine/DataDict/Mssql.php
$notnull = (isset($field['notnull']) && $field['notnull']) ? ' NOT NULL' : '';
should be
$notnull = (isset($field['notnull']) && $field['notnull']) ? ' NOT NULL' : ' NULL';
This fixes the issue for us and hasn't created any problems thus far.