8219彩票网

SELECT COUNT(id) as sp_counter FROM () sp_tmp_table_pager1
执行错误: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') sp_tmp_table_pager1' at line 1

34.          $this->arrSql[] = $sql;
35.          if( $result mysql_query($sql$this->conn) ){
36.              return $result;
37.          }else{
38.              if(mysql_error()!=''){
39.                  syError("{$sql}<br />执行错误: " mysql_error());
40.              }else{
41.                  return TRUE;
42.              }
43.          }
44.      }
3.  class db_mysql {
4.      public $conn;
5.      public $arrSql;
6.      public function getArray($sql)
7.      {
8.          if( ! $result $this->exec($sql) )return array();
9.          if( ! mysql_num_rows($result) )return array();
10.          $rows = array();
11.          while($rows[] = mysql_fetch_array($result,MYSQL_ASSOC)){}
12.          mysql_free_result($result);
13.          array_pop($rows);
118.          return $this->update($conditions, array($field=>$value));
119.      }
120. 
121.      public function findSql($sql)
122.      {
123.          return $this->_db->getArray($sql);
124.      }
125. 
126.      public function runSql($sql)
127.      {
128.          return $this->_db->exec($sql);
270.          $page $this->input_args[0];
271.          if($page==0)$page=1;
272.          $pageSize $this->input_args[1];
273.          @list($conditions$sort$fields ) = $func_args;
274.          if('findSql'==$func_name){
275.              $a=$this->model_obj->findSql("SELECT COUNT({$this->model_obj->pk}) as sp_counter FROM ($conditions) sp_tmp_table_pager1");
276.              $a=array_pop$a );
277.              $total_count array_pop$a );
278.          }else{
279.              $total_count $this->model_obj->findCount($conditions);
280.          }
251.          return $this;
252.      }
253. 
254.      public function __call($func_name$func_args){
255.          if( ( 'findAll' == $func_name || 'findSql' == $func_name ) && != $this->input_args[0]){
256.              return $this->runpager($func_name$func_args);
257.          }elseif(method_exists($this,$func_name)){
258.              return call_user_func_array(array($this$func_name), $func_args);
259.          }else{
260.              return call_user_func_array(array($this->model_obj$func_name), $func_args);
261.          }
220.              $sql="select * from ".$this->db."_field  a left join ".$this->db." b on a.aid=b.id where tj_keywords like '%".$data."%' ";
221.              break;
222.          }
223.          
224.      
225.          $this->lists $this->Class->syPager($this->syArgs('page',0,1),1000)->findSql($sql); 
226.              
227.          $pages=$this->Class->syPager()->getPager();
228.          $this->pages=pagetxt($pages);
229.          $list_c=$this->lists;
230.          foreach($list_c as $k=>$v){
220.              $sql="select * from ".$this->db."_field  a left join ".$this->db." b on a.aid=b.id where tj_keywords like '%".$data."%' ";
221.              break;
222.          }
223.          
224.      
225.          $this->lists $this->Class->syPager($this->syArgs('page',0,1),1000)->findSql($sql); 
226.              
227.          $pages=$this->Class->syPager()->getPager();
228.          $this->pages=pagetxt($pages);
229.          $list_c=$this->lists;
230.          foreach($list_c as $k=>$v){
7.      $handle_controller syClass($__controllernull$GLOBALS['G_DY']["controller_path"].'/'.$__controller.".php");
8.      if(!is_object($handle_controller) || !method_exists($handle_controller$__action)){
9.          syError('route Error');
10.          exit;
11.      }
12.      $handle_controller->$__action();
13.      if(FALSE != $GLOBALS['G_DY']['view']['auto_display']){
14.          $__tplname $__controller.$GLOBALS['G_DY']['view']['auto_display_sep'].
15.                  $__action.$GLOBALS['G_DY']['view']['auto_display_suffix']; 
16.          $handle_controller->auto_display($__tplname);
17.      }
1.  <?php
2. 
3.  require("config.php");
4.  $doyoConfig['view']['config']['template_dir'] = APP_PATH.'/template/'.$doyoConfig['ext']['view_themes'];
5.  require(DOYO_PATH."/sys.php");
6.  spRun();
旭彩网 - 首页 汇彩网welcome - 首页 泰彩网tai88888.com