I am receiving a syntax error:
MySQL said: Documentation
#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 ‘-1) NULL, PRIMARY KEY
(diagram_id), UNIQUE INDEX
UK_principal_name (p’ at line 6
This is what i am trying to run. i have looked that the lines it is telling me is incorrect and i have yet to find the correct syntax to use. any help would be appreciated.
DROP TABLE IF EXISTS `teamfocus_dbo`.`sysdiagrams`;
CREATE TABLE `teamfocus_dbo`.`sysdiagrams` (
`name` VARCHAR(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL,
`principal_id` INT(10) NOT NULL,
`diagram_id` INT(10) NOT NULL AUTO_INCREMENT,
`version` INT(10) NULL,
`definition` VARBINARY(-1) NULL,
PRIMARY KEY (`diagram_id`),
UNIQUE INDEX `UK_principal_name` (`principal_id`, `name`)
)
ENGINE = INNODB;
Try changing the
VARBINARY(-1)to a positive length, likeVARBINARY(1)