select a.title,a.tid,a.gourl,a.description,a.trait,b.*,c.big_carousel,c.s_carousel,c.pcbrandhotelpic,c.pcbrandhotelpic_1 from jy_pcbrand as a left join jy_pcbrand_field as b on a.id=b.aid left join jy_hotelmap_field as c on b.hotel_id=c.hotelid where a.tid=57 and b.type= and b.hotel_id='H67001' and c.open_pic='1' and a.isshow='1'
执行错误: 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 'and b.hotel_id='H67001' and c.open_pic='1' and a.isshow='1'' 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);
119.          return $this->update($conditions, array($field=>$value));
120.      }
121. 
122.      public function findSql($sql)
123.      {
124.          return $this->_db->getArray($sql);
125.      }
126. 
127.      public function runSql($sql)
128.      {
129.          return $this->_db->exec($sql);
146.          $type=$this->type=addslashes(strval(trim($_GET['type'])));
147.          $hotel_id=$this->hotel_id=addslashes(strval(trim($_GET['hotel_id'])));//酒店id
148.          $tid 57//pc品牌酒店管理  栏目id
149. 
150.          //三表查询
151.          $saleoff_list=syClass('symodel')->findsql("select a.title,a.tid,a.gourl,a.description,a.trait,b.*,c.big_carousel,c.s_carousel,c.pcbrandhotelpic,c.pcbrandhotelpic_1 from ".$GLOBALS['G_DY']['db']['prefix']."pcbrand as a left join ".$GLOBALS['G_DY']['db']['prefix']."pcbrand_field as b on a.id=b.aid left join ".$GLOBALS['G_DY']['db']['prefix']."hotelmap_field as c on b.hotel_id=c.hotelid  where a.tid=".$tid." and  b.type=".$type." and b.hotel_id='".$hotel_id."' and c.open_pic='1' and a.isshow='1'");
152. 
153.          //获取大轮播图、小图 及 各种属性值;
154.          $hotel_arr = array();
155.          $room_arr = array();
156.          $food_arr = array();
11.      $handle_controller syClass($__controllernull$GLOBALS['G_DY']["controller_path"].'/'.$__controller.".php");
12.      if(!is_object($handle_controller) || !method_exists($handle_controller$__action)){
13.          syError('route Error');
14.          exit;
15.      }
16.      $handle_controller->$__action();
17.      if(FALSE != $GLOBALS['G_DY']['view']['auto_display']){
18.          $__tplname $__controller.$GLOBALS['G_DY']['view']['auto_display_sep'].
19.                  $__action.$GLOBALS['G_DY']['view']['auto_display_suffix']; 
20.          $handle_controller->auto_display($__tplname);
21.      }
7.          $doyoConfig['view']['config']['template_dir'] = APP_PATH.'/template/pc';
8.  }
9.  $doyoConfig['controller_path'] = APP_PATH.'/source/pc';
10. 
11.  require(DOYO_PATH."/sys.php");
12.  spRun();
13. 
14. 
15.  //error_reporting(E_ALL);
16.  //ini_set('display_errors','On');
17.  //require("config.php");