$conditions['field1&field2'] = array($f1,$f2,'_multi'=>true);
$RowCount = $User->where($conditions)->Count();
if($RowCount == 1){
//TODO 只有一条记录
}else{
//TODO 记录数量不等于1
}
本文共 215 字,大约阅读时间需要 1 分钟。
$conditions['field1&field2'] = array($f1,$f2,'_multi'=>true);
$RowCount = $User->where($conditions)->Count();
if($RowCount == 1){
//TODO 只有一条记录
}else{
//TODO 记录数量不等于1
}
转载于:https://my.oschina.net/guancen/blog/164419