2023-06-12 17:54:32 -541649 [Druid-ConnectionPool-Create-1101249838] ERROR - create connection error java.sql.SQLSyntaxErrorException: Unknown database 'ljlbank' at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:120) at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97) at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122) at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:836) at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:456) at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:246) at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:197) at com.alibaba.druid.filter.FilterChainImpl.connection_connect(FilterChainImpl.java:148) at com.alibaba.druid.filter.stat.StatFilter.connection_connect(StatFilter.java:211) at com.alibaba.druid.filter.FilterChainImpl.connection_connect(FilterChainImpl.java:142) at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1377) at com.alibaba.druid.pool.DruidAbstractDataSource.createPhysicalConnection(DruidAbstractDataSource.java:1431) at com.alibaba.druid.pool.DruidDataSource$CreateConnectionThread.run(DruidDataSource.java:1844) 2023-06-12 17:55:02 -571661 [Druid-ConnectionPool-Create-1101249838] ERROR - create connection error
时间: 2023-06-23 16:00:44 浏览: 155
mysql-connector-java-8.0.23.zip druid-1.2.8.jar 资源包
这个错误提示和上一个问题类似,也是关于数据库连接的错误。错误信息中的"Unknown database 'ljlbank'"提示说找不到名为'ljlbank'的数据库。可能是因为数据库不存在,或者连接数据库时指定的数据库名有误。检查一下数据库名是否正确,以及数据库是否已经创建好了。另外,也可以检查一下数据库连接用户名和密码是否正确。
阅读全文