LoginLog::where(‘logout_time’, null)
->count(‘DISTINCT user_id’);
解析后的sql:
SELECT COUNT(DISTINCT user_id
) AS tp_count FROM login_log
WHERE logout_time
IS NULL
(tp5.1)
1.如需转载本站原创文章,请务必注明文章出处并附上链接,非常感谢。
2.本站用于记录个人 工作、学习、生活,非商业网站,更多信息请 点击这里