UPDATE user SET viewcount=viewcount+1 WHERE id=20
执行错误: Unknown column 'viewcount' in 'field list'

57.      {
58.          $this->arrSql[] = $sql;
59.          if( $result mysql_query($sql$this->conn) ){
60.              return $result;
61.          }else{
62.              spError("{$sql}<br />执行错误: " mysql_error());
63.          }
64.      }
65.      
66.      /**
67.       返回影响行数
212.       *
213.       * @param sql 字符串,需要执行的SQL语句
214.       */
215.      public function runSql($sql)
216.      {
217.          return $this->_db->exec($sql);
218.      }
219.      // query是runSql的别名,向前兼容
220.      public function query($sql){return $this->runSql($sql);}
221. 
222.      /**
215.      public function runSql($sql)
216.      {
217.          return $this->_db->exec($sql);
218.      }
219.      // query是runSql的别名,向前兼容
220.      public function query($sql){return $this->runSql($sql);}
221. 
222.      /**
223.       返回最后执行的SQL语句供分析
224.       */
225.      public function dumpSql()
425.          $this->id $id;
426.          $this->shop $this->tUser->find(array('id'=>$id));
427.          
428.          //热度+1
429.          $sql "UPDATE user SET viewcount=viewcount+1 WHERE id=$id";
430.          $this->tPub->query($sql);
431.          
432.          //计算产品数量
433.          $sql "SELECT COUNT(*) AS pd_count FROM pd WHERE uid=$id";
434.          $pd_counter $this->tPub->findSql($sql);
435.          $this->pd_counter $pd_counter[0];
16.      if(!is_object($handle_controller) || !method_exists($handle_controller$__action)){
17.          eval($GLOBALS['G_SP']["dispatcher_error"]);
18.          exit;
19.      }
20.      // 路由并执行用户代码
21.      $handle_controller->$__action();
22.      // 控制器程序运行完毕,进行模板的自动输出
23.      if(FALSE != $GLOBALS['G_SP']['view']['auto_display']){
24.          $__tplname $__controller.$GLOBALS['G_SP']['view']['auto_display_sep'].
25.                  $__action.$GLOBALS['G_SP']['view']['auto_display_suffix']; // 拼装模板路径
26.          $handle_controller->auto_display($__tplname);
56.      'mode'=>'debug',
57.      
58.  );
59.  require(SP_PATH."/SpeedPHP.php");
60.  error_reporting(0);
61.  spRun();