Мои комментарии

PDOException Object ( [message:protected] => SQLSTATE[42000]: Syntax error or access violation: 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 'ORDER BY comments.id DESC' at line 4 [string:Exception:private] => [code:protected] => 42000 [file:protected] => /web/blok-optom.ru/protected/src/functions.php [line:protected] => 72 [trace:Exception:private] => Array ( [0] => Array ( [file] => /web/blok-optom.ru/protected/src/functions.php [line] => 72 [function] => query [class] => PDO [type] => -> [args] => Array ( [0] => SELECT * FROM comments LEFT JOIN (SELECT g.id as place_id, g.cat_id as goodCatsId, g.title as place_good_name, g.link as place_good_link, gc.id as goodCatId, gc.title as goodTitle, gc.link as goodLink FROM goods as g, goods_cats as gc WHERE g.cat_id = gc.id) as placeGoods ON comments.place_id = placeGoods.place_id AND comments.place = 0 LEFT JOIN (SELECT n.id as place_id, n.title as place_blog_name, n.link as place_blog_link, cb.id as goodCatId, cb.title as blogTitle, cb.link as postLink FROM news as n, cat_blog as cb WHERE n.cat_id = cb.id) as placeNews ON comments.place_id = placeNews.place_id AND comments.place = 1 LEFT JOIN (SELECT id as place_id, title as place_shares_name, link as place_share_link FROM shares) as placeShares ON comments.place_id = placeShares.place_id AND comments.place = 2 WHERE comments.user_id = ORDER BY comments.id DESC ) ) [1] => Array ( [file] => /web/blok-optom.ru/protected/general/кабинет/комментарии.act [line] => 18 [function] => db_select [args] => Array ( [0] => comments LEFT JOIN (SELECT g.id as place_id, g.cat_id as goodCatsId, g.title as place_good_name, g.link as place_good_link, gc.id as goodCatId, gc.title as goodTitle, gc.link as goodLink FROM goods as g, goods_cats as gc WHERE g.cat_id = gc.id) as placeGoods ON comments.place_id = placeGoods.place_id AND comments.place = 0 LEFT JOIN (SELECT n.id as place_id, n.title as place_blog_name, n.link as place_blog_link, cb.id as goodCatId, cb.title as blogTitle, cb.link as postLink FROM news as n, cat_blog as cb WHERE n.cat_id = cb.id) as placeNews ON comments.place_id = placeNews.place_id AND comments.place = 1 LEFT JOIN (SELECT id as place_id, title as place_shares_name, link as place_share_link FROM shares) as placeShares ON comments.place_id = placeShares.place_id AND comments.place = 2 [1] => * [2] => comments.user_id = ORDER BY comments.id DESC ) ) [2] => Array ( [file] => /web/blok-optom.ru/protected/src/functions.php [line] => 210 [args] => Array ( [0] => /web/blok-optom.ru/protected/general/кабинет/комментарии.act ) [function] => include ) [3] => Array ( [file] => /web/blok-optom.ru/protected/src/functions.php [line] => 221 [function] => get_lay [args] => Array ( [0] => кабинет/комментарии.act ) ) [4] => Array ( [file] => /web/blok-optom.ru/index.php [line] => 56 [function] => get_lay [args] => Array ( [0] => кабинет.act ) ) ) [previous:Exception:private] => [errorInfo] => Array ( [0] => 42000 [1] => 1064 [2] => 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 'ORDER BY comments.id DESC' at line 4 ) )
РасположениеСодержаниеДатаСтатус