数据库出错

2016-07-07 15:17 来源:www.chinab4c.com 作者:ecshop专家

MySQL server error report:Array ( [0] => Array ( [message] => MySQL Query Error ) [1] => Array ( [sql] => SELECT g.goods_id, g.goods_name, g.click_count, g.market_price, g.is_new, g.is_best, g.is_hot, g.is_zt, g.shop_price AS org_price, IFNULL(mp.user_price, g.shop_price * '1') AS shop_price, g.promote_price, g.promote_start_date, g.promote_end_date, g.goods_thumb, g.goods_img, g.goods_brief, g.goods_type FROM `zs1021_db`.`mb_goods` AS g LEFT JOIN `zs1021_db`.`mb_member_price` AS mp ON mp.goods_id = g.goods_id AND mp.user_rank = '0' WHERE g.is_delete = 0 AND g.is_on_sale = 1 AND g.is_alone_sale = 1 AND (( 1 AND g.is_new = 1 ) ) ORDER BY goods_id DESC LIMIT 10 ) [2] => Array ( [error] => Unknown column 'g.is_zt' in 'field list' ) [3] => Array ( [errno] => 1054 ) )

回答:
你的数据库跟你的程序不配套,缺少字段。

你的程序应该是二次开发过的,二次开发过程中增加了新字段

修复下表