java.sql.SQLException: Access denied for user 'Administrator'@'localhost'

我在整合mybatis和spring的时候,测试数据库连接时报了标题所示错误,我的数据库连接配置如下:

driver=com.mysql.jdbc.Driver
url=jdbc:mysql://localhost:3306/seckill?useUnicode=true&characterEncoding=utf8
username=root
password=123

 

找了很久都不知道为什么错了,最后把username改成user就好了。应该是username这个变量和系统的某个变量冲突了。

 

转 : https://blog.csdn.net/czr11616/article/details/84991424

 

posted @ 2020-05-08 16:42  与f  阅读(405)  评论(0编辑  收藏  举报