Can not issue data manipulation statements with executeQuery().该怎么解决

Can not issue data manipulation statements with executeQuery().该怎么解决

Can not issue data manipulation statements with executeQuery().
    Can not issue data manipulation statements with executeQuery().
   当你在做连接数据的时候你肯定会碰到这种问题的,
   现在我至少明白:1、我做的是更新数据库,所以不需要Statement.executeQuery(sql)这一句
                2、还有你在建数据库的时候最好设置主键和唯一,不然调试要很久的
   希望对你们有帮助,OK
------解决方案--------------------
一看到Query就知道是查询用的
------解决方案--------------------
query是查询用的,而update是插入和更新,删除修改用的