+----------------------------------------------------------
* @param mixed $where 数据
* @param string $tables 数据表名
* @param string $fields 字段名
* @param string $order 排序
* @param string $limit
* @param string $group
* @param string $having
* @param boolean $cache 是否缓存
* @param boolean $lazy 是否惰性加载
* @param boolean $lock 是否加锁
+----------------------------------------------------------
* @return ArrayObject
+----------------------------------------------------------
* @throws ThinkExecption
+----------------------------------------------------------
*/
public function find($where,$tables,$fields='*',$order=null,$limit=null,$group=null,$having=null,$join=null,$cache=false,$lazy=false,$lock=false)
{
if(in_array($this->getDbType(),array('MSSQL','IBASE'),true) ) {
$this->queryStr = 'SELECT '.$this->parseLimit($limit)
.$this->parseFields($fields)
.' FROM '.$tables
.$this->parseJoin($join)
.$this->parseWhere($where)
.$this->parseGroup($group)
.$this->parseHaving($having)
.$this->parseOrder($order);
}else{
$this->queryStr = 'SELECT '.$this->parseFields($fields)
.' FROM '.$tables
.$this->parseJoin($join)
.$this->parseWhere($where)
.$this->parseGroup($group)
.$this->parseHaving($having)
.$this->parseOrder($order);
if("ORACLE" == $this->getDbType())
if($limit[0]
if($limit[1] > 0)
$this->queryStr = "SELECT * FROM (".$this->queryStr.") WHERE ROWNUM
}else{
$whereClause = "";
if($limit[1] > 0)
$whereClause = " WHERE ROWNUM
$this->queryStr = "SELECT * FROM ( SELECT ROW_.*, ROWNUM ROWNUM_ FROM ("
.$this->queryStr.") ROW_"
.$whereClause
.") WHERE ROWNUM_ > "
.$limit[0];
}
else
$this->queryStr .= $this->parseLimit($limit);
}
return $this->query('',$cache,$lazy,$lock);
}
0
0
本站声明:本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
热门AI工具
相关专题
2026赚钱平台入口大全
2026年最新赚钱平台入口汇总,涵盖任务众包、内容创作、电商运营、技能变现等多类正规渠道,助你轻松开启副业增收之路。阅读专题下面的文章了解更多详细内容。
76
2026.01.31
无需付费的漫画app大全
想找真正免费又无套路的漫画App?本合集精选多款永久免费、资源丰富、无广告干扰的优质漫画应用,涵盖国漫、日漫、韩漫及经典老番,满足各类阅读需求。阅读专题下面的文章了解更多详细内容。
67
2026.01.31
漫画免费在线观看地址大全
想找免费又资源丰富的漫画网站?本合集精选2025-2026年热门平台,涵盖国漫、日漫、韩漫等多类型作品,支持高清流畅阅读与离线缓存。阅读专题下面的文章了解更多详细内容。
19
2026.01.31
热门下载
相关下载
精品课程
相关推荐
/
热门推荐
/
最新课程







