error ครับ >>>You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'order by id desc limit 10,10' at line 1
select * from product where status='y' and num!='0' and(ckMoney= order by id desc limit 10,10;
ผิดตรงนี้ครับ แต่ผมดูจากโค๊ดมัีนไม่น่าจะเป็นแบบนี้ มีอะไรมากกว่านี้หรือเปล่าครับ
select * from product where status='y' and num!='0' and(ckMoney= order by id desc limit 10,10;
อันนี้เป็นโค้ดทั้งหมดครับ
หน้าแรกมันก็ select * from product where status='y' and num!='0' and(ckMoney='08-2011') order by id desc limit 0,10; ได้ปกตินะครับ
หรือว่าเป็นที่ตรงนี้ครับ
if (($mmonth!="") and ($myear!="")) {
$ckmy="$mmonth-$myear";
$qsearch6="and(ckMoney='$ckmy')";
}