simple-ddl-parser
simple-ddl-parser copied to clipboard
MySQL - UNIQUE in Create Table with constraint name
parse_results = DDLParser("""
CREATE TABLE `api_tokenbucket` (
`id` INT(11) NOT NULL AUTO_INCREMENT,
`value` VARCHAR(80),
UNIQUE `constraint_name`(
`value`
)
);
"""
, silent=False).run(output_mode='mysql')
The above fails to parse. It works if we remove
'constraint_name'
Cheers