idea中原先是这样配置的:
1
2
3
4
|
driver=com.mysql.jdbc.Driver url=jdbc:mysql: //localhost :3306 /ssm ?useUnicode= true &characterEncoding=utf8 username=root password=root |
修改后:
1
2
3
4
|
jdbc.driverClassName=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql: //localhost :3306 /ssm ?useUnicode= true &characterEncoding=utf8 jdbc.username=root jdbc.password=root |
或者如下 同样可以:
1
2
3
4
|
driver=com.mysql.jdbc.Driver url=jdbc:mysql: //localhost :3306 /ssm ?useUnicode= true &characterEncoding=utf8 user=root password=root |
总结:只要不直接写成username就可以