Linux编译mysql8.0.15报错,求大神

/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在函数‘Json_dom_ptr merge_doms(Json_dom_ptr, Json_dom_ptr)’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:112:12: 错误:无法将左值‘Json_object_ptr {aka std::unique_ptr}’绑定到‘std::unique_ptr&&’
return left_object;
^
In file included from /usr/local/include/c++/4.8.4/memory:81:0,
from /usr/local/src/mysql-8.0.15/sql/json_dom.h:29,
from /usr/local/src/mysql-8.0.15/sql/json_dom.cc:23:
/usr/local/include/c++/4.8.4/bits/unique_ptr.h:169:2: 错误:以初始化‘std::unique_ptr<_Tp, _Dp>::unique_ptr(std::unique_ptr<_Up, _Ep>&&) [with _Up = Json_object; _Ep = std::default_delete; = void; _Tp = Json_dom; _Dp = std::default_delete]的实参 1
unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:125:10: 错误:无法将左值‘Json_array_ptr {aka std::unique_ptr}’绑定到‘std::unique_ptr&&’
return left_array;
^
In file included from /usr/local/include/c++/4.8.4/memory:81:0,
from /usr/local/src/mysql-8.0.15/sql/json_dom.h:29,
from /usr/local/src/mysql-8.0.15/sql/json_dom.cc:23:
/usr/local/include/c++/4.8.4/bits/unique_ptr.h:169:2: 错误:以初始化‘std::unique_ptr<_Tp, _Dp>::unique_ptr(std::unique_ptr<_Up, _Ep>&&) [with _Up = Json_array; _Ep = std::default_delete; = void; _Tp = Json_dom; _Dp = std::default_delete]’实参 1
unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在成员函数‘virtual Json_dom_ptr Json_object::clone() const’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:1010:10: 错误:无法将左值‘Json_object_ptr {aka std::unique_ptr}’绑定到‘std::unique_ptr&&’
return o;
^
In file included from /usr/local/include/c++/4.8.4/memory:81:0,
from /usr/local/src/mysql-8.0.15/sql/json_dom.h:29,
from /usr/local/src/mysql-8.0.15/sql/json_dom.cc:23:
/usr/local/include/c++/4.8.4/bits/unique_ptr.h:169:2: 错误:以初始化‘std::unique_ptr<_Tp, _Dp>::unique_ptr(std::unique_ptr<_Up, _Ep>&&) [with _Up = Json_object; _Ep = std::default_delete; = void; _Tp = Json_dom; _Dp = std::default_delete]的实参 1
unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在成员函数‘virtual Json_dom_ptr Json_array::clone() const’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:1150:10: 错误:无法将左值‘Json_array_ptr {aka std::unique_ptr}’绑定到‘std::unique_ptr&&’
return vv;
^
In file included from /usr/local/include/c++/4.8.4/memory:81:0,
from /usr/local/src/mysql-8.0.15/sql/json_dom.h:29,
from /usr/local/src/mysql-8.0.15/sql/json_dom.cc:23:
/usr/local/include/c++/4.8.4/bits/unique_ptr.h:169:2: 错误:以初始化‘std::unique_ptr<_Tp, _Dp>::unique_ptr(std::unique_ptr<_Up, _Ep>&&) [with _Up = Json_array; _Ep = std::default_delete; = void; _Tp = Json_dom; _Dp = std::default_delete]’实参 1
unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在函数‘Json_dom_ptr merge_doms(Json_dom_ptr, Json_dom_ptr)’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:127:1: 警告:在有返回值的函数中,控制流程到达函数尾 [-Wreturn-type]
}
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在成员函数‘virtual Json_dom_ptr Json_object::clone() const’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:1012:1: 警告:在有返回值的函数中,控制流程到达函数尾 [-Wreturn-type]
}
^
/usr/local/src/mysql-8.0.15/sql/json_dom.cc: 在成员函数‘virtual Json_dom_ptr Json_array::clone() const’中:
/usr/local/src/mysql-8.0.15/sql/json_dom.cc:1152:1: 警告:在有返回值的函数中,控制流程到达函数尾 [-Wreturn-type]
}
^
make[2]: *** [sql/CMakeFiles/sql_main.dir/json_dom.cc.o] 错误 1
make[1]: *** [sql/CMakeFiles/sql_main.dir/all] 错误 2
make: *** [all] 错误 2

1个回答

删除sql_main.dir,调大内存,从新cmake和make

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
Python+OpenCV计算机视觉

Python+OpenCV计算机视觉

.net 4.0 项目 连接mysql8.0.15 使用MySql.Data.dll 连接的时候报错

string connectStr = "Server=localhost;port=3306;Database=xxx;User ID=root;Password=xxx;"; MySqlConnection conn = new MySqlConnection(connectStr);//仍还没有建立连接 try { conn.Open();//建立连接 //string sql = "select * from users";//sql语句 //MySqlCommand cmd = new MySqlCommand(sql, conn);//建立命令 } catch(MySqlException ex) { } 异常信息: Authentication to host 'localhost' for user 'root' using method 'caching_sha2_password' failed with message: Access denied for user 'root'@'localhost' (using password: YES) 请问一下,mysql8.0.15不支持net4.0吗 我尝试修改验证方式: alter user ‘root’@'localhost' identified with mysql_native_password by '密码'; 但是也没用 详细异常信息 在 MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.AuthenticationFailed(Exception ex) 在 MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.ReadPacket() 在 MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.ContinueAuthentication(Byte[] data) 在 MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.Authenticate(Boolean reset) 在 MySql.Data.MySqlClient.NativeDriver.Open() 在 MySql.Data.MySqlClient.Driver.Open() 在 MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings) 在 MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnection() 在 MySql.Data.MySqlClient.MySqlPool.GetPooledConnection() 在 MySql.Data.MySqlClient.MySqlPool.TryToGetDriver() 在 MySql.Data.MySqlClient.MySqlPool.GetConnection() 在 MySql.Data.MySqlClient.MySqlConnection.Open() 在 ConsoleAppMySql.Program.Connection() 位置 G:\数据库例子\ConsoleAppMySql\ConsoleAppMySql\Program.cs:行号 29

刚安装的MySQL 8.0.15执行net start MySQL时服务名无效

sc delete mysql [SC] DeleteService 成功 net start mysql 服务名无效。 请键入 NET HELPMSG 2185 以获得更多的帮助。

mysql忘记密码了按网上重置密码教程出错怎么办

![图片说明](https://img-ask.csdn.net/upload/201708/10/1502350749_738790.jpg) 这是什么问题 应该输入 mysqld --skip-grant-tables这个DOS命令窗口不可动了啊

我的数据库版本是8.0的 它还让我升级?

十一月 25, 2018 10:20:42 下午 org.springframework.context.support.ClassPathXmlApplicationContext prepareRefresh 信息: Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@47089e5f: startup date [Sun Nov 25 22:20:42 CST 2018]; root of context hierarchy 十一月 25, 2018 10:20:42 下午 org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions 信息: Loading XML bean definitions from class path resource [spring-dao.xml] org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Client does not support authentication protocol requested by server; consider upgrading MySQL client) at org.apache.commons.dbcp.BasicDataSource.createPoolableConnectionFactory(BasicDataSource.java:1549) at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1388) at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044) at day06.DataSourceTest.testConnection(DataSourceTest.java:24) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:41) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:541) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:763) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:463) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:209) Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Client does not support authentication protocol requested by server; consider upgrading MySQL client at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.Util.getInstance(Util.java:381) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:984) at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3558) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3490) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:919) at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3996) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1284) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2137) at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:776) at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:46) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) at java.lang.reflect.Constructor.newInstance(Unknown Source) at com.mysql.jdbc.Util.handleNewInstance(Util.java:406) at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:352) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:284) at org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:38) at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:582) at org.apache.commons.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:1556) at org.apache.commons.dbcp.BasicDataSource.createPoolableConnectionFactory(BasicDataSource.java:1545) ... 26 more 十一月 25, 2018 10:20:43 下午 org.springframework.context.support.ClassPathXmlApplicationContext doClose 信息: Closing org.springframework.context.support.ClassPathXmlApplicationContext@47089e5f: startup date [Sun Nov 25 22:20:42 CST 2018]; root of context hierarchy![图片说明](https://img-ask.csdn.net/upload/201811/25/1543156327_576065.png) 今天我想测试一下eclipse能不能连到mysql上 可是他报错 提示我让我升级数据库 我的数据库是8.0.12的 应该不低才对啊 import org.apache.commons.dbcp.BasicDataSource; import org.junit.Test; import org.springframework.context.support.AbstractApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; public class DataSourceTest { @Test public void testConnection() { AbstractApplicationContext ac=new ClassPathXmlApplicationContext("spring-dao.xml"); BasicDataSource ds=ac.getBean("dataSource",BasicDataSource.class); Connection conn=null; try { conn=ds.getConnection(); System.out.println(conn); } catch (Exception e) { e.printStackTrace(); }finally { if(conn!=null) { try { conn.close(); } catch (SQLException e) { e.printStackTrace(); } } } ac.close(); } } 这是代码,希望大哥帮下

mysql重装以后,之前所有表报1146,表不存在的错误,怎么修复表?

mysql重装以后,之前所有表报1146,表不存在的错误,怎么修复表?

如何在django中使用mysql自带的MySQL Connector Python 8.0 for Python 3.7?

django连接mysql提示 django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module. Did you install mysqlclient? 也就是说要我pip install mysqlclient 可我安装mysql的时候自带MySQL Connector Python 8.0 for Python 3.7 C:\Program Files\MySQL\MySQL Connector Python 8.0 for Python 3.7 也就是说我只要告诉django连接mysql用这个目录里的文件就好了... 可我怎么才能让django知道这件事...

MySQL 8.0,服务无法启动,还有本地计算机上的mysql服务启动后停止。某些服务在未由其他服务或程序使用时将自动停止

我按照如下顺序安装MySQL并启动服务: ## 1、把MySQL压缩版安装到H盘下** ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059174_143218.png) 这是我安装后的结果 ## 2、执行:mysqld --initialize -insecure ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059252_644444.png) ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059292_663846.png) ## 3、执行:H:\mysql-8.0.18-winx64\bin\mysqld --install ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059469_471803.png) ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059549_160259.png) ## 4、执行:net start mysql ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059651_79740.png) 为什么会出现这个错误?这个怎么解决? ## 5、在服务窗口启动服务也会弹出这个: ![图片说明](https://img-ask.csdn.net/upload/201910/26/1572059781_592481.png) 请问各位大神这个怎么解决?

在安装MySQL的过程中 中输入mysqld --initialize --console时为什么出现标注的错误的代码?

在环境变量以及my.ini文件都正好以后 再Cmd输入mysqld --initialize --consol之后出现了以下神秘代码。。这是为什么? E:\SQL\mysql-8.0.15-winx64>mysqld --initialize --console mysqld: Can't create directory 'C:\Program Files\MySQL\Data\' (OS errno 2 - No such file or directory) 2019-03-26T16:13:27.803255Z 0 [System] [MY-013169] [Server] E:\SQL\mysql-8.0.15-winx64\bin\mysqld.exe (mysqld 8.0.15) initializing of server in progress as process 10504 2019-03-26T16:13:27.803525Z 0 [ERROR] [MY-010338] [Server] Can't find error-message file 'C:\Program Files\MySQL\share\errmsg.sys'. Check error-message file location and 'lc-messages-dir' configuration directive. 2019-03-26T16:13:27.805036Z 0 [Warning] [MY-013242] [Server] --character-set-server: 'utf8' is currently an alias for the character set UTF8MB3, but will be an alias for UTF8MB4 in a future release. Please consider using UTF8MB4 in order to be unambiguous. 2019-03-26T16:13:27.809940Z 0 [ERROR] [MY-013236] [Server] Newly created data directory C:\Program Files\MySQL\Data\ is unusable. You can safely remove it. 2019-03-26T16:13:27.876969Z 0 [ERROR] [MY-010119] [Server] Aborting 2019-03-26T16:13:27.877380Z 0 [System] [MY-010910] [Server] E:\SQL\mysql-8.0.15-winx64\bin\mysqld.exe: Shutdown complete (mysqld 8.0.15) MySQL Community Server - GPL. ``` 图在此(https://img-ask.csdn.net/upload/201903/27/1553617467_17340.png) ``` 以下是我配置的图片

包引用了,MySQL8.0.17版本,用的jar包是8.0.18的,但是一直报错

java.lang.ClassNotFoundException: com.mysql.cj.jdbc.driver at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) at util.try1.main(try1.java:29) 数据库连接失败 代码 package util; import java.beans.Statement; import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import com.mysql.cj.jdbc.Driver; public class try1 { private static String DBUrl="jdbc:mysql://localhost:3306/bishe?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf-8&useSSL=false"; private static String DBUser="root"; private static String DBPwd="xsj123..0"; public static Connection conn=null; public static ResultSet rs=null; public static PreparedStatement pst=null; public static void main(String[] args) { // TODO Auto-generated method stub try { String Driver = "com.mysql.cj.jdbc.driver"; Class.forName(Driver); } catch (ClassNotFoundException e) { // TODO Auto-generated catch block e.printStackTrace(); System.out.println("数据库连接失败"); } try { DriverManager.getConnection(DBUrl, DBUser, DBPwd); } catch (SQLException e1) { // TODO Auto-generated catch block e1.printStackTrace(); System.out.println("数据库连接失败1"); }

mysql8.0跟tomcat7.0有冲突吗

我用mysql8.0+mysql-connector-java-8.0.15+jdk1.8能通过jdbc访问数据库,但是将服务部署到tomcat7.0服务器时出错,初步认定是没能成功访问数据库,报错信息如下: 严重: Servlet.service() for servlet [LoginServlet] in context with path [/day0513] threw exception [Servlet execution threw an exception] with root cause java.lang.UnsupportedClassVersionError: com/mysql/cj/jdbc/Driver : Unsupported major.minor version 52.0 (unable to load class com.mysql.cj.jdbc.Driver) ``` at org.apache.catalina.loader.WebappClassLoaderBase.findClassInternal(WebappClassLoaderBase.java:3255) at org.apache.catalina.loader.WebappClassLoaderBase.findClass(WebappClassLoaderBase.java:1420) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1924) at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1798) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:190) at com.fubr.dao.Dao.getUserByUsernameAndPwd(Dao.java:14) at com.fubr.service.UserService.login(UserService.java:24) at com.fubr.servlet.LoginServlet.doPost(LoginServlet.java:25) at javax.servlet.http.HttpServlet.service(HttpServlet.java:650) at javax.servlet.http.HttpServlet.service(HttpServlet.java:731) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:494) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:1025) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1137) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:317) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:744) ``` 求大神解答,在线等

android APP连接mysql时,APP闪退

安卓程序连接MySQL一直不成功,本地连接可以。我是用手机调试的,点击接mysql按钮时,APP闪退。在网上找了好多方法都不行。求看看什么问题 错误日志如下: 2019-08-25 08:25:33.377 5570-5570/mark.zhang E/AndroidRuntime: FATAL EXCEPTION: main Process: mark.zhang, PID: 5570 java.lang.IllegalStateException: Could not execute method for android:onClick at android.view.View$DeclaredOnClickListener.onClick(View.java:5692) at android.view.View.performClick(View.java:6663) at android.view.View.performClickInternal(View.java:6635) at android.view.View.access$3100(View.java:794) at android.view.View$PerformClick.run(View.java:26199) at android.os.Handler.handleCallback(Handler.java:907) at android.os.Handler.dispatchMessage(Handler.java:105) at android.os.Looper.loop(Looper.java:216) at android.app.ActivityThread.main(ActivityThread.java:7625) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987) Caused by: java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at android.view.View$DeclaredOnClickListener.onClick(View.java:5687) at android.view.View.performClick(View.java:6663)  at android.view.View.performClickInternal(View.java:6635)  at android.view.View.access$3100(View.java:794)  at android.view.View$PerformClick.run(View.java:26199)  at android.os.Handler.handleCallback(Handler.java:907)  at android.os.Handler.dispatchMessage(Handler.java:105)  at android.os.Looper.loop(Looper.java:216)  at android.app.ActivityThread.main(ActivityThread.java:7625)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)  Caused by: java.lang.BootstrapMethodError: Exception from call site #39 bootstrap method at com.mysql.cj.jdbc.AbandonedConnectionCleanupThread.<clinit>(AbandonedConnectionCleanupThread.java:58) at java.lang.Class.classForName(Native Method) at java.lang.Class.forName(Class.java:453) at java.lang.Class.forName(Class.java:378) at com.mysql.cj.jdbc.NonRegisteringDriver.<clinit>(NonRegisteringDriver.java:99) at java.lang.Class.classForName(Native Method) at java.lang.Class.forName(Class.java:453) at java.lang.Class.forName(Class.java:378) at mark.zhang.Util.openConnection(Util.java:16) at mark.zhang.Main.onConn(Main.java:30) at java.lang.reflect.Method.invoke(Native Method)  at android.view.View$DeclaredOnClickListener.onClick(View.java:5687)  at android.view.View.performClick(View.java:6663)  at android.view.View.performClickInternal(View.java:6635)  at android.view.View.access$3100(View.java:794)  at android.view.View$PerformClick.run(View.java:26199)  at android.os.Handler.handleCallback(Handler.java:907)  at android.os.Handler.dispatchMessage(Handler.java:105)  at android.os.Looper.loop(Looper.java:216)  at android.app.ActivityThread.main(ActivityThread.java:7625)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)  Caused by: java.lang.ClassCastException: Bootstrap method returned null at com.mysql.cj.jdbc.AbandonedConnectionCleanupThread.<clinit>(AbandonedConnectionCleanupThread.java:58)  at java.lang.Class.classForName(Native Method)  at java.lang.Class.forName(Class.java:453)  at java.lang.Class.forName(Class.java:378)  at com.mysql.cj.jdbc.NonRegisteringDriver.<clinit>(NonRegisteringDriver.java:99)  at java.lang.Class.classForName(Native Method)  at java.lang.Class.forName(Class.java:453)  at java.lang.Class.forName(Class.java:378)  at mark.zhang.Util.openConnection(Util.java:16)  at mark.zhang.Main.onConn(Main.java:30)  at java.lang.reflect.Method.invoke(Native Method)  at android.view.View$DeclaredOnClickListener.onClick(View.java:5687)  at android.view.View.performClick(View.java:6663)  at android.view.View.performClickInternal(View.java:6635)  at android.view.View.access$3100(View.java:794)  at android.view.View$PerformClick.run(View.java:26199)  at android.os.Handler.handleCallback(Handler.java:907)  at android.os.Handler.dispatchMessage(Handler.java:105)  at android.os.Looper.loop(Looper.java:216)  at android.app.ActivityThread.main(ActivityThread.java:7625)  at java.lang.reflect.Method.invoke(Native Method)  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)  at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)  2019-08-25 08:25:33.398 5570-5570/mark.zhang I/Process: Sending signal. PID: 5570 SIG: 9 源码如下: 这是util.java ``` package mark.zhang; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; public class Util { public static Connection openConnection(String url, String user, String password) { Connection conn = null; try { final String DRIVER_NAME = "com.mysql.cj.jdbc.Driver"; Class.forName(DRIVER_NAME); conn = DriverManager.getConnection(url, user, password); } catch (ClassNotFoundException e) { conn = null; } catch (SQLException e) { conn = null; } return conn; } public static void query(Connection conn, String sql) { if (conn == null) { return; } Statement statement = null; ResultSet result = null; try { statement = conn.createStatement(); result = statement.executeQuery(sql); if (result != null && result.first()) { int idColumnIndex = result.findColumn("id"); int nameColumnIndex = result.findColumn("name"); System.out.println("id\t\t" + "name"); while (!result.isAfterLast()) { System.out.print(result.getString(idColumnIndex) + "\t\t"); System.out.println(result.getString(nameColumnIndex)); result.next(); } } } catch (SQLException e) { e.printStackTrace(); } finally { try { if (result != null) { result.close(); result = null; } if (statement != null) { statement.close(); statement = null; } } catch (SQLException sqle) { } } } public static boolean execSQL(Connection conn, String sql) { boolean execResult = false; if (conn == null) { return execResult; } Statement statement = null; try { statement = conn.createStatement(); if (statement != null) { execResult = statement.execute(sql); } } catch (SQLException e) { execResult = false; } return execResult; } } ``` 这是main.java ``` package mark.zhang; import com.mysql.cj.jdbc.AbandonedConnectionCleanupThread; import java.sql.Connection; import java.sql.SQLException; import androidx.appcompat.app.AppCompatActivity; import android.app.Activity; import android.os.Bundle; import android.view.View; import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; public class Main extends Activity { private static final String REMOTE_IP = "223.104.64.237"; private static final String URL = "jdbc:mysql://223.104.64.237:3306/mydb?useSSL=false&serverTimezone=GMT&characterEncoding=utf-8&autoReconnect=true"; private static final String USER = "root"; private static final String PASSWORD = "123"; private Connection conn; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } public void onConn(View view) { conn = Util.openConnection(URL, USER, PASSWORD); /* final Thread thread = new Thread(new Runnable() { @Override public void run() { // 反复尝试连接,直到连接成功后退出循环 while (!Thread.interrupted()) { try { Thread.sleep(100); // 每隔0.1秒尝试连接 } catch (InterruptedException e) { System.out.println("链接数据库"); } // 2.设置好IP/端口/数据库名/用户名/密码等必要的连接信息 String url="jdbc:mysql://223.104.64.237:3306/mydb?useSSL=false&serverTimezone=Hongkong&characterEncoding=utf-8&autoReconnect=true"; String user = "root"; String password = "123"; // 3.连接JDBC try { Class.forName("com.mysql.cj.jdbc.Driver"); Connection conn = DriverManager.getConnection(url,user,password); System.out.println("远程连接成功!"); conn.close(); return; } catch (SQLException e) { System.out.println("远程连接失败!"); } catch (ClassNotFoundException e){ } } } }); thread.start();*/ } public void onInsert(View view) { String sql = "insert into mytable values(9, 'hanmeimei')"; Util.execSQL(conn, sql); } public void onDelete(View view) { String sql = "delete from mytable where name='mark'"; Util.execSQL(conn, sql); } public void onUpdate(View view) { String sql = "update mytable set name='李磊' where name='韩美'"; Util.execSQL(conn, sql); } public void onQuery(View view) { System.out.println("All users info:"); Util.query(conn, "select * from mytable"); } @Override protected void onDestroy() { super.onDestroy(); if (conn != null) { try { conn.close(); } catch (SQLException e) { conn = null; } finally { conn = null; } } } } ```

ecplise连接数据库mysql8.0出错

ecplise2019-03连接数据库mysql8.0出错,我的ecplise连接SQL是好的 import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; public class a1 { public static void main(String []args) { Connection conn = null; PreparedStatement ps = null; ResultSet rs = null; // The newInstance() call is a work around for some // broken Java implementations try { Class.forName("com.mysql.jdbc.Driver"); System.out.println("加载成功"); conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/shop?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=UTC","root","qing980104"); System.out.println("连接成功"); } } catch (SQLException ex) { // handle any errors System.out.println("连接失败"); } } } 结果显示 Exception in thread "main" java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521) at java.base/java.lang.Class.forName0(Native Method) at java.base/java.lang.Class.forName(Class.java:315) at experiment1.a1.main(a1.java:7) 我把代码换成运行成功的SQL连接代码,然后改了下 import java.sql.*; public class a1 { public static void main(String[] args) throws SQLException, ClassNotFoundException { // TODO Auto-generated method stub Class.forName("com.mysql.cj.jdbc.Driver"); Connection conn= DriverManager.getConnection(jdbc:mysql://127.0.0.1:3306/shop?serverTimezone=GMT%2B8","root","qing980104"); Statement stm=conn.createStatement(); ResultSet re=stm.executeQuery("select * from book"); while(re.next()) { System.out.println("书名:"+re.getString(1)+"书号:"+re.getString(2)+"价格:"+re.getString(3)); } re.close(); stm.close(); conn.close(); } } 结果显示 Exception in thread "main" java.sql.SQLException: Access denied for user ''@'localhost' (using password: NO) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:129) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:835) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:455) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:240) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:199) at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:677) at java.sql/java.sql.DriverManager.getConnection(DriverManager.java:251) at mysql.connector.java@8.0.15/com.mysql.cj.jdbc.admin.TimezoneDump.main(TimezoneDump.java:70) 我以前写的java课设中连接数据库也是显示上面(using password: NO)这个结果 网上有说是MySQL8.0用了强密码的缘故,我重下装了改成旧方式,但还是不行,我又重装了n次,结果现在只能是旧方式,无法改成强密码方式。而且程序还是不行。求大佬解答

maven更新后war项目报错

我点了update project后,项目就报错了,是怎么回事? ![图片说明](https://img-ask.csdn.net/upload/201805/11/1526006255_114703.png) ![图片说明](https://img-ask.csdn.net/upload/201805/11/1526006266_476125.png) ![图片说明](https://img-ask.csdn.net/upload/201805/11/1526006275_391364.png)

spring+mybatis+druid+mysql为啥会报:spring xml model Validation

小白小连一下,求各路大神指教:用的idea开发spring+mybatis+druid+mysql spring+mybatis+druid为啥为啥会报:spring xml model Validation , 其中加粗字体报spring xml model Validation 而换c3p0不会有spring xml model Validation 我的具体配置如下: applicationcontext.xml: <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:context="http://www.springframework.org/schema/context" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:util="http://www.springframework.org/schema/util" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.2.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.2.xsd http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.2.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-4.3.xsd http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-4.2.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.0.xsd"> <!--开启注解 --> <context:annotation-config /> <!--扫包 --> <context:component-scan base-package="com.cgwllx" /> <!-- 读取jdbc配置 --> <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> <property name="locations"> <list> <!-- jdbc.properties引入--> <value>classpath:jdbc.properties</value> </list> </property> </bean> <!--数据库连接池 druid--> <bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource"> <!--读取值 ${key}--> <property name="**driverClass**" value="${driverClass}" /> <property name="**jdbcUrl**" value="${jdbcUrl}"></property> <property name="**user**" value="${user}" /> <property name="password" value="${password}" /> </bean> <!--Mybatis操作数据库 --> <bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean"> <!--连数据库 --> <property name="dataSource" ref="dataSource" /> <!--xml位置 --> <property name="mapperLocations" value="classpath:com/cgwllx/lxfood/dao/***.xml**" /> <!--PO别名 --> <property name="typeAliasesPackage" value="com.cgwllx.lxfood.dao" /> </bean> <!-- 扫包 扫xml --> <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer"> <property name="basePackage" value="com.cgwllx.lxfood.dao" /> </bean> </beans> 项目结构: ![图片说明](https://img-ask.csdn.net/upload/201904/15/1555300458_94236.png) jdbc.properties为: driverClass=mysql.jdbc.Driver jdbcUrl=mysql://localhost:3306/energizecloud?useUnicode=true&characterEncoding=utf8 user=root password=1234 pom也引入了该有的依赖: <properties> <!-- spring版本号 --> <spring.version>4.3.5.RELEASE</spring.version> </properties> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>8.0.15</version> </dependency> <dependency> <groupId>com.alibaba</groupId> <artifactId>druid</artifactId> <version>1.0.28</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-core</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-oxm</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-tx</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-jdbc</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-webmvc</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-context-support</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-test</artifactId> <version>${spring.version}</version> </dependency> <dependency> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> <version>1.2</version> </dependency> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis</artifactId> <version>3.3.0</version> </dependency> <dependency> <groupId>org.mybatis</groupId> <artifactId>mybatis-spring</artifactId> <version>1.2.2</version> </dependency> <dependency> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> <version>1.2</version> </dependency>

MySQL安装时mysqld --initialize --console没有initializing of server has completed

在安装MySQL时 ![图片说明](https://img-ask.csdn.net/upload/202004/04/1586014867_782784.png) 感觉缺少了一行结果initializing of server has completed,教程中正常结果是这样的:![图片说明](https://img-ask.csdn.net/upload/202004/04/1586014945_506478.png) 我感觉这是导致最后MySQL服务无法启动的原因。有大佬知道到底出了什么问题吗?该如何解决?感谢。 今天将系统升级到1909, 问题已经消失,但仍旧不知道具体原因。 少的那一行只是因为我用的MySQL版本本身就不会有这一行提示。原因肯定不在这里。

springboot 项目报错,可能是数据库连接的问题

java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support. at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:129) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:89) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:63) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:73) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:76) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:835) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:455) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:240) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:199) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.zaxxer.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:136) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.PoolBase.newConnection(PoolBase.java:369) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:198) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:467) [HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.checkFailFast(HikariPool.java:541) [HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.<init>(HikariPool.java:115) [HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:112) [HikariCP-3.2.0.jar:na] at org.springframework.jdbc.datasource.DataSourceUtils.fetchConnection(DataSourceUtils.java:157) [spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.jdbc.datasource.DataSourceUtils.doGetConnection(DataSourceUtils.java:115) [spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:78) [spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.mybatis.spring.transaction.SpringManagedTransaction.openConnection(SpringManagedTransaction.java:82) [mybatis-spring-2.0.0.jar:2.0.0] at org.mybatis.spring.transaction.SpringManagedTransaction.getConnection(SpringManagedTransaction.java:68) [mybatis-spring-2.0.0.jar:2.0.0] at org.apache.ibatis.executor.BaseExecutor.getConnection(BaseExecutor.java:336) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.SimpleExecutor.prepareStatement(SimpleExecutor.java:85) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.SimpleExecutor.doQuery(SimpleExecutor.java:62) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:324) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:156) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:109) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:83) [mybatis-3.5.0.jar:3.5.0] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.apache.ibatis.plugin.Invocation.proceed(Invocation.java:49) [mybatis-3.5.0.jar:3.5.0] at com.github.pagehelper.SqlUtil._processPage(SqlUtil.java:401) [pagehelper-4.1.4.jar:na] at com.github.pagehelper.SqlUtil.processPage(SqlUtil.java:374) [pagehelper-4.1.4.jar:na] at com.github.pagehelper.PageHelper.intercept(PageHelper.java:254) [pagehelper-4.1.4.jar:na] at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:61) [mybatis-3.5.0.jar:3.5.0] at com.sun.proxy.$Proxy79.query(Unknown Source) [na:na] at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:148) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:141) [mybatis-3.5.0.jar:3.5.0] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:433) [mybatis-spring-2.0.0.jar:2.0.0] at com.sun.proxy.$Proxy65.selectList(Unknown Source) [na:na] at org.mybatis.spring.SqlSessionTemplate.selectList(SqlSessionTemplate.java:230) [mybatis-spring-2.0.0.jar:2.0.0] at org.apache.ibatis.binding.MapperMethod.executeForMany(MapperMethod.java:144) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:77) [mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:58) [mybatis-3.5.0.jar:3.5.0] at com.sun.proxy.$Proxy84.queryActivitybyType(Unknown Source) [na:na] at com.elephants.biz.ActivityBiz.selectActivitybyType(ActivityBiz.java:29) [classes/:na] at com.elephants.biz.ActivityBiz$$FastClassBySpringCGLIB$$143d4670.invoke(<generated>) [classes/:na] at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) [spring-core-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:749) [spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) [spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:294) ~[spring-tx-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:98) ~[spring-tx-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) [spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:688) ~[spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at com.elephants.biz.ActivityBiz$$EnhancerBySpringCGLIB$$d9954339.selectActivitybyType(<generated>) ~[classes/:na] at com.elephants.action.ActivityAction.queryActivityByType(ActivityAction.java:32) ~[classes/:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:189) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:102) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:800) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1038) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:942) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1005) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:897) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:882) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-embed-websocket-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:92) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:93) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:200) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:834) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[na:1.8.0_152] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[na:1.8.0_152] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_152] Caused by: com.mysql.cj.exceptions.InvalidConnectionAttributeException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[na:1.8.0_152] at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[na:1.8.0_152] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:61) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:85) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.util.TimeUtil.getCanonicalTimezone(TimeUtil.java:132) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.protocol.a.NativeProtocol.configureTimezone(NativeProtocol.java:2241) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.protocol.a.NativeProtocol.initServerSession(NativeProtocol.java:2265) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.initializePropsFromServer(ConnectionImpl.java:1319) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:966) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:825) ~[mysql-connector-java-8.0.15.jar:8.0.15] ... 110 common frames omitted 2019-03-11 10:20:35.248 ERROR 5184 --- [nio-8080-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.exceptions.PersistenceException: ### Error querying database. Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support. ### The error may exist in file [D:\Twolittleelephants\website\target\classes\mapping\ActivityMapping.xml] ### The error may involve com.elephants.dao.IActivityDao.queryActivitybyType ### The error occurred while executing a query ### Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support.] with root cause com.mysql.cj.exceptions.InvalidConnectionAttributeException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[na:1.8.0_152] at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[na:1.8.0_152] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:61) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:85) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.util.TimeUtil.getCanonicalTimezone(TimeUtil.java:132) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.protocol.a.NativeProtocol.configureTimezone(NativeProtocol.java:2241) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.protocol.a.NativeProtocol.initServerSession(NativeProtocol.java:2265) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.initializePropsFromServer(ConnectionImpl.java:1319) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:966) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:825) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:455) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:240) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:199) ~[mysql-connector-java-8.0.15.jar:8.0.15] at com.zaxxer.hikari.util.DriverDataSource.getConnection(DriverDataSource.java:136) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.PoolBase.newConnection(PoolBase.java:369) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.PoolBase.newPoolEntry(PoolBase.java:198) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.createPoolEntry(HikariPool.java:467) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.checkFailFast(HikariPool.java:541) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.pool.HikariPool.<init>(HikariPool.java:115) ~[HikariCP-3.2.0.jar:na] at com.zaxxer.hikari.HikariDataSource.getConnection(HikariDataSource.java:112) ~[HikariCP-3.2.0.jar:na] at org.springframework.jdbc.datasource.DataSourceUtils.fetchConnection(DataSourceUtils.java:157) ~[spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.jdbc.datasource.DataSourceUtils.doGetConnection(DataSourceUtils.java:115) ~[spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:78) ~[spring-jdbc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.mybatis.spring.transaction.SpringManagedTransaction.openConnection(SpringManagedTransaction.java:82) ~[mybatis-spring-2.0.0.jar:2.0.0] at org.mybatis.spring.transaction.SpringManagedTransaction.getConnection(SpringManagedTransaction.java:68) ~[mybatis-spring-2.0.0.jar:2.0.0] at org.apache.ibatis.executor.BaseExecutor.getConnection(BaseExecutor.java:336) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.SimpleExecutor.prepareStatement(SimpleExecutor.java:85) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.SimpleExecutor.doQuery(SimpleExecutor.java:62) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:324) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:156) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:109) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.executor.CachingExecutor.query(CachingExecutor.java:83) ~[mybatis-3.5.0.jar:3.5.0] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.apache.ibatis.plugin.Invocation.proceed(Invocation.java:49) ~[mybatis-3.5.0.jar:3.5.0] at com.github.pagehelper.SqlUtil._processPage(SqlUtil.java:401) ~[pagehelper-4.1.4.jar:na] at com.github.pagehelper.SqlUtil.processPage(SqlUtil.java:374) ~[pagehelper-4.1.4.jar:na] at com.github.pagehelper.PageHelper.intercept(PageHelper.java:254) ~[pagehelper-4.1.4.jar:na] at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:61) ~[mybatis-3.5.0.jar:3.5.0] at com.sun.proxy.$Proxy79.query(Unknown Source) ~[na:na] at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:148) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:141) ~[mybatis-3.5.0.jar:3.5.0] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:433) ~[mybatis-spring-2.0.0.jar:2.0.0] at com.sun.proxy.$Proxy65.selectList(Unknown Source) ~[na:na] at org.mybatis.spring.SqlSessionTemplate.selectList(SqlSessionTemplate.java:230) ~[mybatis-spring-2.0.0.jar:2.0.0] at org.apache.ibatis.binding.MapperMethod.executeForMany(MapperMethod.java:144) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:77) ~[mybatis-3.5.0.jar:3.5.0] at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:58) ~[mybatis-3.5.0.jar:3.5.0] at com.sun.proxy.$Proxy84.queryActivitybyType(Unknown Source) ~[na:na] at com.elephants.biz.ActivityBiz.selectActivitybyType(ActivityBiz.java:29) ~[classes/:na] at com.elephants.biz.ActivityBiz$$FastClassBySpringCGLIB$$143d4670.invoke(<generated>) ~[classes/:na] at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) ~[spring-core-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:749) ~[spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) ~[spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:294) ~[spring-tx-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:98) ~[spring-tx-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) ~[spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:688) ~[spring-aop-5.1.5.RELEASE.jar:5.1.5.RELEASE] at com.elephants.biz.ActivityBiz$$EnhancerBySpringCGLIB$$d9954339.selectActivitybyType(<generated>) ~[classes/:na] at com.elephants.action.ActivityAction.queryActivityByType(ActivityAction.java:32) ~[classes/:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_152] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_152] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_152] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_152] at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:189) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:102) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:895) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:800) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1038) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:942) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1005) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:897) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:882) ~[spring-webmvc-5.1.5.RELEASE.jar:5.1.5.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) ~[tomcat-embed-websocket-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:92) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:93) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) ~[spring-web-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:200) ~[tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:834) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1415) [tomcat-embed-core-9.0.16.jar:9.0.16] at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_152] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_152] at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) [tomcat-embed-core-9.0.16.jar:9.0.16] at java.lang.Thread.run(Thread.java:748) [na:1.8.0_152]

golang mysql驱动程序无法替换参数

<div class="post-text" itemprop="text"> <p>OS Mojave, MySQL v8.0.15, go 1.12.3 darwin/amd64</p> <pre><code>import ( "database/sql" // import mysql driver anonymously (just run the init) _ "github.com/go-sql-driver/mysql" ) ... _, err = db.db.Exec("USE ?", "test") if err != nil { return errors.Wrapf(err, "error selecting database %s", opt.Database) } _, err = db.db.Prepare("SELECT value FROM ? WHERE key = ?") if err != nil { return errors.Wrap(err, "error generating SELECT statement") } </code></pre> <p>The error I get is <code>error selecting database test: Error 1064: 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 '?' at line 1</code></p> <p>I get the same error (about syntax around '?') for any parameter replacement I attempt to do. I've checked the manual as well as tutorials and examples I've found online and can't quite tell what I'm doing wrong. </p> <p>If I replace the '?'s with values (strings) then everything works fine. </p> </div>

idea中pom.xml无法导入jdbc的jar包

----_这问题勉强已解决,我直接结贴吧_ ------ <br> ```xml <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>5.1.38</version> </dependency> ``` <br /> ![图片说明](https://img-ask.csdn.net/upload/202005/03/1588488360_139685.png) <br/> 查看本地仓库,发现只有下面这个文件: ![图片说明](https://img-ask.csdn.net/upload/202005/03/1588488665_19396.png) <br/> lastupdate内容如下: <br/> ``` #NOTE: This is a Maven Resolver internal implementation file, its format can be changed without prior notice. #Sun May 03 14:48:53 CST 2020 http\://maven.aliyun.com/nexus/content/groups/public/.error=Could not transfer artifact mysql\:mysql-connector-java\:pom\:5.1.38 from/to alimaven (http\://maven.aliyun.com/nexus/content/groups/public/)\: sun.security.validator.ValidatorException\: PKIX path building failed\: sun.security.provider.certpath.SunCertPathBuilderException\: unable to find valid certification path to requested target @default-alimaven-http\://maven.aliyun.com/nexus/content/groups/public/.lastUpdated=1588488533478 ``` <br/> 还有其他几个版本我都无法导入, 已尝试:重新复制粘贴;关闭代理;重启idea;mvn clean/compile; <br/> --------------------------------------------- ---在这记一下解决经过以后留个印象--- 尝试重装了该版本的maven,又下了一个idea2020,仓库备份后清空,settings.xml去掉镜像。 一开始去掉阿里镜像,结果也不行,右侧包括pulgin在内全部飘红,mvn命令除了-v全部error,删掉本地项目后reimport又再次生成的也只有一个lastUpdated文件,报错信息看起来就像是说我少了证书,网上一查让加参数试了也不行,和证书好像没啥关系。 后来新建了一个新maven项目,reimport终于有反应了,然后回到老项目里重新剪切粘贴reimport,这次终于可以从中央仓库下载依赖了,虽然速度慢,但加上[阿里镜像](https://help.aliyun.com/document_detail/102512.html?spm=a2c4e.11153940.0.0.213c7bdePMchQS)就不行了,应该是镜像问题,也不知道今天怎么突然就这样了。我意识到两点: - 网速不行确实会造成mvn命令执行失败,但不会像这样一直失败,重新执行一次即可; - 如果中途加了settings.xml文件的mirror,再次reimport,结果失败pom文件飘红,造成即使立刻注释掉mirror点刷新也没有反应,重启一下idea。

无法连接到MySQL:用户'root'@'localhost'拒绝访问

<div class="post-text" itemprop="text"> <blockquote> <p>Could not connect to MySQL: Access denied for user 'root'@'localhost' (using password: NO)</p> </blockquote> <p>我不能使用用户名(Root)访问我的数据库,也不能使用任何密码,我该怎么办?我也不能通过MySQL控制台访问。我试图配置config.inc.php文件,但没有作用。</p> <p>请告诉我如何不丢弃WAMP,也不需要重新装载。</p> <p>十分感谢</p> <p>Aleksandar</p> </div>

2019 Python开发者日-培训

2019 Python开发者日-培训

150讲轻松搞定Python网络爬虫

150讲轻松搞定Python网络爬虫

设计模式(JAVA语言实现)--20种设计模式附带源码

设计模式(JAVA语言实现)--20种设计模式附带源码

YOLOv3目标检测实战:训练自己的数据集

YOLOv3目标检测实战:训练自己的数据集

java后台+微信小程序 实现完整的点餐系统

java后台+微信小程序 实现完整的点餐系统

三个项目玩转深度学习(附1G源码)

三个项目玩转深度学习(附1G源码)

初级玩转Linux+Ubuntu(嵌入式开发基础课程)

初级玩转Linux+Ubuntu(嵌入式开发基础课程)

2019 AI开发者大会

2019 AI开发者大会

玩转Linux:常用命令实例指南

玩转Linux:常用命令实例指南

一学即懂的计算机视觉(第一季)

一学即懂的计算机视觉(第一季)

4小时玩转微信小程序——基础入门与微信支付实战

4小时玩转微信小程序——基础入门与微信支付实战

Git 实用技巧

Git 实用技巧

Python数据清洗实战入门

Python数据清洗实战入门

使用TensorFlow+keras快速构建图像分类模型

使用TensorFlow+keras快速构建图像分类模型

实用主义学Python(小白也容易上手的Python实用案例)

实用主义学Python(小白也容易上手的Python实用案例)

程序员的算法通关课:知己知彼(第一季)

程序员的算法通关课:知己知彼(第一季)

MySQL数据库从入门到实战应用

MySQL数据库从入门到实战应用

机器学习初学者必会的案例精讲

机器学习初学者必会的案例精讲

手把手实现Java图书管理系统(附源码)

手把手实现Java图书管理系统(附源码)

极简JAVA学习营第四期(报名以后加助教微信:eduxy-1)

极简JAVA学习营第四期(报名以后加助教微信:eduxy-1)

.net core快速开发框架

.net core快速开发框架

玩转Python-Python3基础入门

玩转Python-Python3基础入门

Python数据挖掘简易入门

Python数据挖掘简易入门

微信公众平台开发入门

微信公众平台开发入门

程序员的兼职技能课

程序员的兼职技能课

Windows版YOLOv4目标检测实战:训练自己的数据集

Windows版YOLOv4目标检测实战:训练自己的数据集

HoloLens2开发入门教程

HoloLens2开发入门教程

微信小程序开发实战

微信小程序开发实战

Java8零基础入门视频教程

Java8零基础入门视频教程

相关热词 c#跨线程停止timer c#批量写入sql数据库 c# 自动安装浏览器 c#语言基础考试题 c# 偏移量打印是什么 c# 绘制曲线图 c#框体中的退出函数 c# 按钮透明背景 c# idl 混编出错 c#在位置0处没有任何行
立即提问