:(

1064: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 g.is_sell=1 and g.ex_goods_cid=14 ) ORDER BY g.sort,g.add_time desc' at line 1 [ SQL语句 ] : SELECT g.goods_id,g.goods_sn,g.uid,g.exid,g.goods_cate_id,g.goods_type,g.goods_name,g.goods_thumb,g.goods_img,g.goods_num,g.is_creat_ord,g.goods_price,g.goods_postage,g.remark,g.is_rec,g.goods_introduce,g.is_sell,g.sort,g.add_time,c.excname FROM bd_goods g left JOIN bd_ex_cate as c on g.ex_goods_cid=c.excid WHERE ( g.exid= and g.is_sell=1 and g.ex_goods_cid=14 ) ORDER BY g.sort,g.add_time desc

错误位置

FILE: /alidata/www/900ku/ThinkPHP/Library/Think/Db/Driver.class.php  LINE: 350

TRACE

#0 /alidata/www/900ku/ThinkPHP/Library/Think/Db/Driver.class.php(350): E('1064:You have a...')
#1 /alidata/www/900ku/ThinkPHP/Library/Think/Db/Driver.class.php(180): Think\Db\Driver->error()
#2 /alidata/www/900ku/ThinkPHP/Library/Think/Db/Driver.class.php(946): Think\Db\Driver->query('SELECT g.goods_...', false)
#3 /alidata/www/900ku/ThinkPHP/Library/Think/Model.class.php(601): Think\Db\Driver->select(Array)
#4 /alidata/www/900ku/Apps/Home/Model/goodsModel.class.php(19): Think\Model->select()
#5 /alidata/www/900ku/Apps/Home/Controller/ShopController.class.php(161): Home\Model\goodsModel->goodsdata('g.exid= and g.i...', Array, 30)
#6 [internal function]: Home\Controller\ShopController->search_cate()
#7 /alidata/www/900ku/ThinkPHP/Library/Think/App.class.php(217): ReflectionMethod->invoke(Object(Home\Controller\ShopController))
#8 /alidata/www/900ku/ThinkPHP/Library/Think/App.class.php(154): Think\App::invokeAction(Object(Home\Controller\ShopController), 'search_cate')
#9 /alidata/www/900ku/ThinkPHP/Library/Think/App.class.php(248): Think\App::exec()
#10 /alidata/www/900ku/ThinkPHP/Library/Think/Think.class.php(120): Think\App::run()
#11 /alidata/www/900ku/ThinkPHP/ThinkPHP.php(97): Think\Think::start()
#12 /alidata/www/900ku/index.php(171): require('/alidata/www/90...')
#13 {main}