$query = CdbForumSellthreadSearch::where($params)->orderBy("$orderby", "$ascDesc")->offset($start)->limit($limit);
$list = CdbForumSellthreadSearch::where($params)->orderBy("$orderby", "$ascDesc")->offset($start)->limit($limit)->get()->toArray();

 

//打印出的sql是预编译的sql语句,带有问号占位符的sql 

print_r($query->toSql());

 

//下面打印出占位符对应的变量的值,数组里面的顺序和占位符的顺序是一致的

echo '<pre>';

print_r($query->getBindings());

exit;

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-11-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-01-14
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案