The MySQL server is running with the --read-only option so it cannot execute this statement
来源:互联网 发布:程序员女神 赵洁琼 编辑:程序博客网 时间:2024/06/10 03:10
1、错误描述
Caused by: java.sql.SQLException: The MySQL server is running with the --read-only option so it cannot execute this statementat com.mysql.jdbc.SQLError.createSQLException(SQLError.java:996)at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3887)at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3823)at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2435)at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2582)at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2530)at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1907)at com.mysql.jdbc.PreparedStatement.execute(PreparedStatement.java:1199)at org.apache.ibatis.executor.statement.PreparedStatementHandler.query(PreparedStatementHandler.java:56)at org.apache.ibatis.executor.statement.RoutingStatementHandler.query(RoutingStatementHandler.java:70)at sun.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)at java.lang.reflect.Method.invoke(Method.java:606)at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:59)at com.sun.proxy.$Proxy36.query(Unknown Source)at org.apache.ibatis.executor.ReuseExecutor.doQuery(ReuseExecutor.java:54)at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:259)at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:132)at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:105)at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:81)at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:104)at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:98)at org.apache.ibatis.session.defaults.DefaultSqlSession.selectOne(DefaultSqlSession.java:62)at sun.reflect.GeneratedMethodAccessor66.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)at java.lang.reflect.Method.invoke(Method.java:606)at core.util.CustomSqlSessionTemplate$SqlSessionInterceptor.invoke(CustomSqlSessionTemplate.java:305)... 81 more
2、错误原因
数据库表设置成只读,但是在修改更新操作时用到这张表,导致报错
3、解决办法
(1)将只读属性改为可写可读
(2)新建一张可读的数据库表
0 0
- The MySQL server is running with the --read-only option so it cannot execute this statement
- 1209 - The MySQL server is running with the --read-only option so it cannot execute this statement
- The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement
- The MySQL server is running with the --secure-file-priv option so it cannot execute this statement解决
- The MySQL server is running with the --secure-file-priv option so it cannot execute this statement解决
- The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement
- MySQL报错:The MySQL server is running with the --skip-grant-tables option so it cannot execute this st
- MySQL报错:The MySQL server is running with the --skip-grant-tables option so it cannot execute this st
- MYSQL导出数据出现The MySQL server is running with the --secure-file-priv option so it cannot execute this
- mysql错误:`The MySQL server is running with the --skip-grant-tables option so it cannot execute this s
- Caused by: java.sql.SQLException: The MySQL server is running with the --read-only option so it cann
- 关于The MySQL server is running with the--skip-grant-tables option so it cannot execute thisstatement
- ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot exe
- ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot exe
- ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot exe
- ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot exe
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot exe
- 暑期-dp46道(2)
- spring MVC框架下 前台向java后台传送json字符串数据
- UVA10719Quotient Polynomial
- Android中的ScrollView
- 大素数测试和大数素因子分解
- The MySQL server is running with the --read-only option so it cannot execute this statement
- leetcode——Intersection of Two Arrays II
- 某服务请求经负载均衡设备分配到集群A、B、C、D进行处理响应的概率分别是10%、20%、30%和40%。已知测试集群所得的稳定性指标分别是90%、95%、99%和99.9%。现在该服务器请求处理失败,
- js实现全选和反选功能
- 小心!新媒体环境下,营销传播还有几个大坑!
- unity中鼠标和触摸问题
- 什么是野指针?如何避免野指针?
- HDU 5562 Clarke and five-pointed star (BC)
- July 15th 模拟赛C T4 回家(莫名其妙【推荐】) Solution