Why are these comments in a mysql file blowing up?
On the Linux command line I call this script via the mysql terminal using source...
--First insert new template types
insert into TemplateType(id,name,size)
values (10,'Feature Sheet','8.5x11 ss');
insert into TemplateType(id,name,size)
开发者_如何学JAVA values (11,'Feature Sheet','8.5x11 ds');
insert into TemplateType(id,name,size)
values (12,'Feature Sheet','11x17');
When I do I get an error saying my sql syntax is invalid. Is this not the correct way to comment an sql file?
Apparently you need whitespace after the -- or use a # instead....
http://dev.mysql.com/doc/refman/5.0/en/comments.html
精彩评论