【发布时间】:2017-02-16 04:39:28
【问题描述】:
我想在 yii2 中使用 activerecord 查询访问前一个我的数据库表中的最后一条记录。
例如这样:
$query = Product::find()
->where(['NOT IN', 'price_off', ''])
->orderBy('id DESC')
->limit('1,1') //But this limit not work correctlly
->one();
This page 没有帮助我。
【问题讨论】:
标签: mysql yii yii2 yii2-advanced-app