显示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 '--创表语句
create table goods(goodsName varchar(20),price decimal(4, 2));
没问题啊,你是用程序执行 还是工具。程序执行估计是分号的问题 你去掉试试