Chinaunix

标题: MySQL使用相关间题 [打印本页]

作者: liuxingyuyuni    时间: 2006-03-15 01:39
标题: MySQL使用相关间题

乱码问题:
$conn->query("Set Names 'gb2312'");
或使用iconv函数.
----------------------------------
连接数据库出现:
Client does not support authentication protocol requested
by server; consider upgrading MySQL client
---------------------------------
解决:
one:
mysql> SET PASSWORD FOR
-> 'some_user'@'some_host' = OLD_PASSWORD('newpwd');
two:
mysql> UPDATE mysql.user SET Password = OLD_PASSWORD('newpwd')
-> WHERE Host = 'some_host' AND User = 'some_user';
mysql> FLUSH PRIVILEGES;


本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/10599/showart_85381.html




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2