namespace app\index\controller;
use think\Db;
class Index
{
public function index()
{
Db::table('users')->where('id',1)->find();
}
}
请问怎么引入Db,这样报错
[2] ErrorException in Db.php line 114
call_user_func_array() expects parameter 1 to be a valid callback, class 'think\db\driver\Mysql' does not have a method 'table'
最佳答案