## LIMIT ~~~ <?php namespace Action; use HY\Action; class Index extends Action { public function Index(){ //实例User表为对象 $User = M("User"); $User->select("account", "user_id", array( "GROUP" => "type", // 必须有使用它与小组一起 "HAVING" => array( "user_id[>]" => 500 ), // LIMIT => 20 "LIMIT" => array(20, 100) )); // SELECT user_id FROM account // GROUP BY type // HAVING user_id > 500 // LIMIT 20,100 } } ~~~