ThinkChat🤖让你学习和工作更高效,注册即送10W Token,即刻开启你的AI之旅 广告
# Count 通过条件 检索数据的数量 > count($where) 中文 : 总数(条件); where (optional) [array] WHERE 条件. * * * * * > count( $join, $column, $where) join [array] 多表查询. column [string] 需要统计的字段. where (optional) [array] WHERE 条件. * * * * * > Return: [number] 行的数量. 返回的是数字类型. ~~~ $User = S("User"); //查看 user = admin 有多少数目 $count = $User->count(array( "user" => "admin" )); //查找User表的数据总数 $All_count = $User->count(); ~~~