- 论坛徽章:
- 0
|
PHP5+mysql6出現查詢錯誤
比如:
select * from A where id in (1,2,3) order by username desc; 非主键排序,返回空
select * from A where id in (1,2,3) order by id desc ; 主键排序,有返回值
select * from A where id in (1,2,3) ; 不排序,有返回值
类似:
select * from A where id >1 order by username desc; 非主键排序,返回空
select * from A where id >1 order by id desc; 主键排序,有返回值
select * from A where id >1 ; 不排序,有返回值
注: 此處id為主鍵,username不是
而同樣的語句在php5+mysql5中正常
PHP5+MYSQL6,PHPMYADMIN給的警告
Your PHP MySQL library version 5.0.45 differs from your MySQL server version 6.0.3. This may cause unpredictable behavior.
是哪里出了问题呢?php or mysql ?
謝謝拉.... |
|