$con = new PDO("mysql:host=localhost;dbname=test",'root','');
$start = 1;
$rows = 5;
$sql = "select * from users limit :start,:rows";
$sth = $con->prepare($sql);
$sth->execute(array(':start'=>$start,':rows'=>$rows));
$arr = $sth->fetchAll();
print_r($arr);
$con = null;请问大神这个是哪儿出问题了
添加回答
举报
0/150
提交
取消