SELECT p.autor, p.tresc, p.data, u.id
FROM pages_com p
LEFT OUTER JOIN users u on p.autor = u.username
WHERE p.wpis = ?
ORDER BY p.id DESC
我的错误是:
1064 - 您的SQL语法出错;检查与MySQL服务器版本对应的手册,以获得正确的语法 靠近'?按顺序执行DES。限制0,30和#39;在第4行
我的代码:
$query = "SELECT p.autor, p.tresc, p.data, u.id
FROM pages_com p
LEFT OUTER JOIN users u on p.autor = u.username
WHERE p.wpis = ?
ORDER BY p.id DESC";
$statement = $databaseConnection->prepare($query);
$statement->bind_param('s', $id);
fucntion bind_param中的错误:
致命错误:在非对象中调用成员函数bind_param() 第81行/home/p503373/public_html/v2/page.php