问答详情
源自:2-2 JDBC实战---打通数据库

求解主机不允许连接数据库是什么错

Exception in thread "main" java.sql.SQLException: null,  message from server: "Host 'DESKTOP-O852FIL' is not allowed to connect to this MySQL server"

用户名root密码没错

报这个错是哪里出了问题啊?

提问者:沃特麦冷 2017-05-29 11:07

个回答

  • qq_莫非
    2017-05-31 13:09:08

    可能是数据库不能被原创访问,只能是localhost访问。