Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:Win7 64-bit
Netbeans 6.9.1
Symfony 1.4.8
Description
doing a
doctrine:build --all --and-load
with a schema.yml of
Foo:
tableName: foo
options:
charset: utf8
columns:
bar:
type: tinyint(1)
default: 0
results in a blank value generated for the default keyword, and the following error:
SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 ENGINE = INNODB' at line 1. Failing Query: "CREATE TABLE foo (id BIGINT AUTO_INCREMENT, bar tinyint(1) DEFAULT , PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 ENGINE = INNODB". Failing Query: CREATE TABLE foo (id BIGINT AUTO_INCREMENT, bar tinyint(1) DEFAULT , PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 ENGINE = INNODB
I've also tried combinations of tinyint, tinyint(4), single-quoting the default value, and different default values.
Changing the type to int makes the issue disappear