MySQL Forums
Forum List  »  MySQL Workbench

Foward Engineer SQL create...Never seem to work
Posted by: Chris Thorley
Date: February 17, 2009 03:24PM

I have tried to export a set of tables from Workbench using "Foward Engineer SQL create..." and I cant seem to get the script to import via any import application or command line due to the following error:-

Does anyone know why this is the case becaus ethey are really siple tables and all InnoDB so its all bit of a waste of time right now.


Query:
CREATE TABLE IF NOT EXISTS `projects` (
`projectId` INT(11) NOT NULL AUTO_INCREMENT ,
`projectName` VARCHAR(225) NULL DEFAULT NULL ,
`briefDescription` NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
PRIMARY KEY (`projectId`) )
ENGINE = InnoDB
AUTO_INCREMENT = 503


Error occured at:2009-02-17 21:17:42
Line no.:11
Error Code: 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 'NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
PRIMARY KEY (`projectId`) )
E' at line 4

Query:
CREATE TABLE IF NOT EXISTS `projects` (
`projectId` INT(11) NOT NULL AUTO_INCREMENT ,
`projectName` VARCHAR(225) NULL DEFAULT NULL ,
`briefDescription` NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
PRIMARY KEY (`projectId`) )
ENGINE = InnoDB
AUTO_INCREMENT = 503


Error occured at:2009-02-17 21:19:02
Line no.:11
Error Code: 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 'NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
PRIMARY KEY (`projectId`) )
E' at line 4

Query:
CREATE TABLE IF NOT EXISTS `projects` (
`projectId` INT(11) NOT NULL AUTO_INCREMENT ,
`projectName` VARCHAR(225) NULL DEFAULT NULL ,
`briefDescription` NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
`type` NOT NULL ,
`status` NOT NULL ,
`active` NOT NULL DEFAULT 1 COMMENT '1 is active\n2 is inactive\n3 is delete' ,
`site` NULL ,
PRIMARY KEY (`projectId`) )
ENGINE = InnoDB
AUTO_INCREMENT = 503

Error occured at:2009-02-17 21:20:48
Line no.:32
Error Code: 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 'NULL DEFAULT NULL ,
`stakeHolders` NOT NULL ,
`type` NOT NULL ,
`status`' at line 4

Options: ReplyQuote


Subject
Views
Written By
Posted
Foward Engineer SQL create...Never seem to work
3483
February 17, 2009 03:24PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.